struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dennis Muhlestein <>
Subject html:rewrite possible bug
Date Mon, 05 May 2003 17:38:51 GMT
We use the rewrite tag occasionally within some javascript.  We have
never used it with more than one parameter until today.

Today when trying though, the outputted html is incorrect.

<%      java.util.Hashtable parms = new java.util.Hashtable();
         parms.put ( "PARAM1", "1" );
         parms.put ( "PARAM2", "2" );
         pageContext.setAttribute( "parms", parms ); %>
     function MsgWindow()
             newWindow = open("<html:rewrite href="/SomeLink"
name="parms" />", .......

The expcted Output is /SomeLink?PARAM1=1&PARAM2=2

Instead, we get /SomeLink?PARAM1=1&amp;PARAM2=2
(NOTE THE &amp;)

Our workaround for right now is to use a small jsp code snippet to write 
  our own parameter string, then pass that string to the href parameter 
of the rewrite tag.

Is this a known issue?  Something is double encoding the parameter 
string.  Should I file a bug on this?  It seems like a small issue to 
fix before 1.1.

html:rewrite & sslext:rewrite are affected the same way.

Neither html:link or sslext:link show this behavior. (Docs say they
should behave the same minus the "<a href..." part)

We are using 1.1rc1 but also tried this with the nightly build: 20030501


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message