You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-scm@portals.apache.org by ta...@apache.org on 2008/11/19 00:17:36 UTC

svn commit: r718760 - /portals/pluto/trunk/pluto-taglib/src/main/java/org/apache/pluto/tags/BaseURLTag.java

Author: taylor
Date: Tue Nov 18 15:17:35 2008
New Revision: 718760

URL: http://svn.apache.org/viewvc?rev=718760&view=rev
Log:
https://issues.apache.org/jira/browse/PLUTO-523
The action test was failing because it failed to parse the URL correctly

Modified:
    portals/pluto/trunk/pluto-taglib/src/main/java/org/apache/pluto/tags/BaseURLTag.java

Modified: portals/pluto/trunk/pluto-taglib/src/main/java/org/apache/pluto/tags/BaseURLTag.java
URL: http://svn.apache.org/viewvc/portals/pluto/trunk/pluto-taglib/src/main/java/org/apache/pluto/tags/BaseURLTag.java?rev=718760&r1=718759&r2=718760&view=diff
==============================================================================
--- portals/pluto/trunk/pluto-taglib/src/main/java/org/apache/pluto/tags/BaseURLTag.java (original)
+++ portals/pluto/trunk/pluto-taglib/src/main/java/org/apache/pluto/tags/BaseURLTag.java Tue Nov 18 15:17:35 2008
@@ -111,9 +111,10 @@
 		
 		//	properly encoding urls to allow non-cookie enabled sessions - PLUTO-252 
 		String urlString = response.encodeURL(url.toString());
-		
-		if(escapeXml){
-			urlString = doEscapeXml(urlString);
+
+ 		if(escapeXml)
+ 		{
+			 urlString = doEscapeXml(urlString);
 		}
 		
 	    if (var == null) {
@@ -345,7 +346,8 @@
      */
     protected String doEscapeXml(String str) {
     	if(!isEmpty(str)){
-    		str = str.replaceAll("&", "&");
+// DST: this is breaking the "ActionParameterTest", since a raw URL with & is getting turned int &, which fails to parse correctly
+//    	    str = str.replaceAll("&", "&");
     		str = str.replaceAll("<", "&lt;");
     		str = str.replaceAll(">", "&gt;");
     		str = str.replaceAll("\"", "&#034;");