On Wed, Jun 23, Kristian Thy wrote:
>       Dear List,
> 
> How can I make it pick up the right object?

An off-list solution made its way to me:

from zExceptions import Redirect
rewritten_url = context.REQUEST['URL'].replace('foo', 'quux')
rewritten_url += '/' + 
'/'.join(reversed(context.REQUEST.TraversalRequestNameStack))
query = context.REQUEST['QUERY_STRING']
if query:
  rewritten_url = '%s?%s' % (rewritten_url, query)
raise Redirect, rewritten_url

Thanks.

\\kristian
-- 
... et nemo ex vobis interrogat me: »Quo vadis?«
_______________________________________________
Zope maillist  -  Zope@zope.org
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to