From 98babf1641668a136cff56235c2d863b75ef113e Mon Sep 17 00:00:00 2001 From: givebest Date: Tue, 24 May 2016 11:29:02 +0800 Subject: [PATCH] Update ajax.js ?t=1&callback= --- ajax.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ajax.js b/ajax.js index d4ffdc9..ad2f606 100644 --- a/ajax.js +++ b/ajax.js @@ -38,7 +38,7 @@ function ajax(options) { document.body.removeChild(script); success(data); } - script.src = url + (url.indexOf("?") > -1 ? "" : "?") + "callback=" + callback; + script.src = url + (url.indexOf("?") > -1 ? "&" : "?") + "callback=" + callback; script.type = "text/javascript"; document.body.appendChild(script); setTime(callback, script); @@ -134,4 +134,4 @@ function ajax(options) { } else { createXHR(); } -} \ No newline at end of file +}