RESPONSE.redirect('blah?var=%s'%url_quote(value) ?
What is the cleanest way of doing the following? <dtml-call "RESPONSE.redirect('index_html?err=%s' % url_quote(errmsg))"> url_quote isn't available in the _ namespace (that I can find...), and I can't work out how to store a url_quote'd string anywhere without using a DTML Method... -- ___ // Zen (alias Stuart Bishop) Work: zen@cs.rmit.edu.au // E N Senior Systems Alchemist Play: zen@shangri-la.dropbear.id.au //__ Computer Science, RMIT WWW: http://www.cs.rmit.edu.au/~zen
Stuart 'Zen' Bishop wrote:
What is the cleanest way of doing the following?
<dtml-call "RESPONSE.redirect('index_html?err=%s' % url_quote(errmsg))">
url_quote isn't available in the _ namespace (that I can find...), and I can't work out how to store a url_quote'd string anywhere without using a DTML Method...
Probably the "cleanest" way, in the sense of not being hackish, is to just make an External Method which imports and calls url_quote. I ended up hacking it into the '_' namespace, along with 'list', 'tuple', 'map', 'filter', 'reduce', and the 'base64' functions. Cheers, Evan @ 4-am
participants (2)
-
Evan Simpson -
Stuart 'Zen' Bishop