dunno about the regex but in python, this is simply : if s[-1] != "/" : s[:string.rfind(s, "/")] which i guess should be something like this : <dtml-if "s[-1]=='/'"> <dtml-call "REQUEST.set(s, s[:_.string.rfind(s, '/')])"> </dtml-if> where s is your path_info (which you sub straight into the above) not sure what you need this for but you might want to check URL1 also. chas
The PATH_INFO is
/kirmess/
or
/kirmess/index_html
depending on how you call the document. I'd like to have it always without the document name. How can I cut everything behind the last / in a string?
Sven
-- PGP-Key-ID: 0x881BF222
_______________________________________________ Zope maillist - Zope@zope.org http://www.zope.org/mailman/listinfo/zope
(Related lists - please, no cross posts or HTML encoding!
To receive general Zope announcements, see: http://www.zope.org/mailman/listinfo/zope-announce
For developer-specific issues, zope-dev@zope.org - http://www.zope.org/mailman/listinfo/zope-dev )