I wanted to use urlparse to handle manage some url rewrites but it's not importable.. Is there any zope functional equivelent that I can use to parse urls? -- David Bear phone: 602-496-0424 fax: 602-496-0955 College of Public Programs/ASU University Center Rm 622 411 N Central Phoenix, AZ 85007-0685 "Beware the IP portfolio, everyone will be suspect of trespassing"
there isn't but you can write an External Method in pure python. On 14/12/2007, David Bear <David.Bear@asu.edu> wrote:
I wanted to use urlparse to handle manage some url rewrites but it's not importable.. Is there any zope functional equivelent that I can use to parse urls?
-- David Bear phone: 602-496-0424 fax: 602-496-0955 College of Public Programs/ASU University Center Rm 622 411 N Central Phoenix, AZ 85007-0685 "Beware the IP portfolio, everyone will be suspect of trespassing" _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
-- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com
On Fri, Dec 14, 2007 at 09:16:54PM +0000, peter@fry-it.com wrote:
there isn't but you can write an External Method in pure python.
On 14/12/2007, David Bear <David.Bear@asu.edu> wrote:
I wanted to use urlparse to handle manage some url rewrites but it's not importable.. Is there any zope functional equivelent that I can use to parse urls?
Thanks for all the responses. I'm a little suprised that there isn't anything like urlparse functionaly in zope. I would think parsing urls would be a fairly common chore. Which leads me to think that I may be thinking completely wrong about what I want to accomplish. Perhaps I can get closer to what I want if I better understand the names 'here' and 'context'. I am writing a python script and I want to get the path to where the script lives -- not from where it was called. But I don't see that 'here' is a name available to script. Yet, 'context' doesn't seem to do what I want. what is the easiest way to get the path to where a script lives? -- David Bear phone: 602-496-0424 fax: 602-496-0955 College of Public Programs/ASU University Center Rm 622 411 N Central Phoenix, AZ 85007-0685 "Beware the IP portfolio, everyone will be suspect of trespassing"
If you print out the contents of 'container.REQUEST' you will find a lot of helpful pre-set url-related vars. Jonathan ----- Original Message ----- From: "David Bear" <David.Bear@asu.edu> To: <peter@fry-it.com> Cc: "zope" <Zope@zope.org> Sent: Friday, December 14, 2007 6:06 PM Subject: Re: [Zope] urlparse equivalent
On Fri, Dec 14, 2007 at 09:16:54PM +0000, peter@fry-it.com wrote:
there isn't but you can write an External Method in pure python.
On 14/12/2007, David Bear <David.Bear@asu.edu> wrote:
I wanted to use urlparse to handle manage some url rewrites but it's not importable.. Is there any zope functional equivelent that I can use to parse urls?
Thanks for all the responses.
I'm a little suprised that there isn't anything like urlparse functionaly in zope. I would think parsing urls would be a fairly common chore. Which leads me to think that I may be thinking completely wrong about what I want to accomplish.
Perhaps I can get closer to what I want if I better understand the names 'here' and 'context'. I am writing a python script and I want to get the path to where the script lives -- not from where it was called. But I don't see that 'here' is a name available to script. Yet, 'context' doesn't seem to do what I want.
what is the easiest way to get the path to where a script lives?
-- David Bear phone: 602-496-0424 fax: 602-496-0955 College of Public Programs/ASU University Center Rm 622 411 N Central Phoenix, AZ 85007-0685 "Beware the IP portfolio, everyone will be suspect of trespassing" _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
-- No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.5.503 / Virus Database: 269.17.2/1184 - Release Date: 12/14/2007 11:29 AM
David Bear skrev:
On Fri, Dec 14, 2007 at 09:16:54PM +0000, peter@fry-it.com wrote:
I'm a little suprised that there isn't anything like urlparse functionaly in zope. I would think parsing urls would be a fairly common chore. Which leads me to think that I may be thinking completely wrong about what I want to accomplish.
You practically newer use urlparse like functionality when scripting and skinning zope. You sometimes do when developing special products, but then you got the entire python library to use. -- hilsen/regards Max M, Denmark http://www.mxm.dk/ IT's Mad Science
participants (5)
-
David Bear -
Jonathan -
Max M -
peter@fry-it.com -
Sean Fulmer