From: Erik Arenhill Date: Thu, 26 Jan 2017 22:13:58 +0000 (+0100) Subject: Now preserves the existing querystring questionmark if there already is one present... X-Git-Tag: 6.3.1~21^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=efcb12ff9f9ffeb470894bae4182b47dfe45fde3;p=thirdparty%2Ffoundation%2Ffoundation-sites.git Now preserves the existing querystring questionmark if there already is one present, and uses an ampersand instead in that case. --- diff --git a/js/foundation.util.timerAndImageLoader.js b/js/foundation.util.timerAndImageLoader.js index b0875ee00..cea9d1c0f 100644 --- a/js/foundation.util.timerAndImageLoader.js +++ b/js/foundation.util.timerAndImageLoader.js @@ -67,7 +67,7 @@ function onImagesLoaded(images, callback){ else { // fix for IE. See https://css-tricks.com/snippets/jquery/fixing-load-in-ie-for-cached-images/ var src = $(this).attr('src'); - $(this).attr('src', src + '?' + (new Date().getTime())); + $(this).attr('src', src + (src.indexOf('?') >= 0 ? '&' : '?') + (new Date().getTime())); $(this).one('load', function() { singleImageLoaded(); });