UTF-8 form input vs. xmlhttp, #71347
authorMark Wells <mark@freeside.biz>
Tue, 5 Jul 2016 23:41:25 +0000 (16:41 -0700)
committerMark Wells <mark@freeside.biz>
Tue, 5 Jul 2016 23:41:25 +0000 (16:41 -0700)
httemplate/elements/xmlhttp.html

index 2f4f0d5..e708711 100644 (file)
@@ -44,7 +44,7 @@ my %initialized = ();#won't work if component is "preloaded"... so don't do that
             len = args.length - 1;
         }
         for (var i = 0; i < len; i++) 
-            content = content + "&arg=" + escape(args[i]);
+            content = content + "&arg=" + encodeURIComponent(args[i]);
         content = content.replace( /[+]/g, '%2B'); // fix unescaped plus signs 
 
         if ( '<%$method%>' == 'GET' ) {