is there a way to get a url-encoded/quoted variable in pythonish dtml ? what i am trying to do <dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)"> Kapil
Kapil Thangavelu wrote:
what i am trying to do <dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)">
<dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)" url_quote> <dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)" url_quote_plus> dependent on whether you want spaces coded as + or %20 cheers, Chris
On Thu, Jul 20, 2000 at 10:06:33AM +0100, Chris Withers wrote:
Kapil Thangavelu wrote:
what i am trying to do <dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)">
<dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)" url_quote>
<dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)" url_quote_plus>
dependent on whether you want spaces coded as + or %20
Didn't happen for me (Zope 2.2b4). I got Invalid attribute name, "url_quote", for tag <dtml-call "REQUEST.set('URL', URL2+'?action=Add Material Info&product_number='+product_number)" url_quote>, on line 195 of index_html It also fails for <dtml-return>... It looks like url_quote is only applicable to <dtml-var>...which is sort of painful.
cheers,
Chris
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
jpenny@universal-fasteners.com wrote:
<dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)" url_quote>
<dtml-call "RESPONSE.redirect(URL1+'?foo_bar='+foobar)" url_quote_plus>
Sorry, brain defect on my part: didn't notice the -call :( I see someone alerady posted what I should have said...
It also fails for <dtml-return>... It looks like url_quote is only applicable to <dtml-var>...which is sort of painful.
not really... how and what would you apply html_quote to in call and return (return is slightly easier) cheers, Chris
participants (3)
-
Chris Withers -
jpennyï¼ universal-fasteners.com -
Kapil Thangavelu