webwork/src/main/webwork/view/velocity URLBean.java,1.10,1.11
[email protected] Tue, 16 May 2006 00:34:10 -0700
| Newsgroups | gmane.comp.java.open-symphony.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/opensymphony/webwork/src/main/webwork/view/velocity
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv22536/src/main/webwork/view/velocity
Modified Files:
URLBean.java
Log Message:
Encode URLs using webwork's encoding, and not the system encoding. This fixes a number of bugs in JIRA :)
I'd raise an issue in Webwork's JIRA instance, but I can't seem to find it now...
Index: URLBean.java
===================================================================
RCS file: /cvsroot/opensymphony/webwork/src/main/webwork/view/velocity/URLBean.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- URLBean.java 19 Mar 2005 19:20:29 -0000 1.10
+++ URLBean.java 16 May 2006 07:34:08 -0000 1.11
@@ -6,6 +6,8 @@
*/
package webwork.view.velocity;
+import webwork.util.URLCodec;
+
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpUtils;
@@ -13,7 +15,6 @@
import java.util.HashMap;
import java.util.Iterator;
import java.util.Hashtable;
-import java.net.URLEncoder;
/**
* A utility class that is used to URL-encode links
@@ -157,7 +158,7 @@
{
link.append(name);
link.append('=');
- link.append(URLEncoder.encode((String) value));
+ link.append(URLCodec.encode((String) value));
}
else
{
@@ -168,7 +169,7 @@
String val = values[i];
link.append(name);
link.append('=');
- link.append(URLEncoder.encode(val));
+ link.append(URLCodec.encode(val));
if (i < values.length - 1)
link.append("&");
}
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642