[Mapbender-commits] r5606 - trunk/mapbender/http/javascripts

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Tue Feb 23 09:18:40 EST 2010


Author: topi
Date: 2010-02-23 09:18:40 -0500 (Tue, 23 Feb 2010)
New Revision: 5606

Modified:
   trunk/mapbender/http/javascripts/geometry.js
Log:
escape linebreaks

Modified: trunk/mapbender/http/javascripts/geometry.js
===================================================================
--- trunk/mapbender/http/javascripts/geometry.js	2010-02-23 14:08:44 UTC (rev 5605)
+++ trunk/mapbender/http/javascripts/geometry.js	2010-02-23 14:18:40 UTC (rev 5606)
@@ -1607,7 +1607,7 @@
 			}		
 			var key = this.getName(i);
 			var value = this.getValue(i);
-			str += "\"" + key + "\":\"" + (value+'').replace(/([\\"'])/g, "\\$1").replace(/\u0000/g, "\\0") + "\"";
+			str += "\"" + key + "\":\"" + (value+'').replace(/([\\"'])/g, "\\$1").replace(/\u0000/g, "\\0").replace(/\n/g, "\\n").replace(/\r/g, "\\r") + "\"";
 		}
 		str += "}";
 	}



More information about the Mapbender_commits mailing list