[Zope] Solved: How to get the url without the domain...

Jonothan Farr jfarr@real.com
Tue, 6 Mar 2001 18:50:15 -0800


> Given the fact that the port number is always present in the absolute_url
> variable (in Zope), it's convenient to use it as a string to delimit the
needed
> part of the url.  If this were not the case, I guess it's possible to use any
> part of the domain name close to the first slash after it.

Boy, that is pretty ugly. What if you move to a different port, or a different
host? All of your DTML breaks? I think I'd use the standard urlparse module in
an external method or PythonScript, if there isn't an even simpler way of doing
it.

--jfarr