]> source.dussan.org Git - jquery.git/commitdiff
Fixed bug #215
authorJörn Zaefferer <joern.zaefferer@gmail.com>
Sun, 1 Oct 2006 15:00:16 +0000 (15:00 +0000)
committerJörn Zaefferer <joern.zaefferer@gmail.com>
Sun, 1 Oct 2006 15:00:16 +0000 (15:00 +0000)
src/ajax/ajax.js

index 1426604bd73909a80a4cfce7602eb68c0dd3f41f..c2549c7be8798b11d74208717627af443081e63d 100644 (file)
@@ -298,7 +298,8 @@ jQuery.extend({
                        data = null;
                }
                
-               if ( data ) url += "?" + jQuery.param(data);
+               // append ? + data or & + data, in case there are already params
+               if ( data ) url += ((url.indexOf("?") > -1) ? "&" : "?") + jQuery.param(data);
                
                // Build and start the HTTP Request
                jQuery.ajax( "GET", url, null, function(r, status) {