From 68bbe65f4576162062a6d8cc216fcda2621d3930 Mon Sep 17 00:00:00 2001 From: Yannick Warnier Date: Fri, 12 Nov 2010 16:15:03 -0500 Subject: [PATCH] Hacked thickbox.js to load the right address for loadingAnimation.gif - prevents *many* file not found error logs --- main/inc/lib/javascript/thickbox.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/main/inc/lib/javascript/thickbox.js b/main/inc/lib/javascript/thickbox.js index d6247c619d..c7a850d28d 100755 --- a/main/inc/lib/javascript/thickbox.js +++ b/main/inc/lib/javascript/thickbox.js @@ -5,7 +5,12 @@ * Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php */ -var tb_pathToImage = "main/img/loadingAnimation.gif"; +// Identify the url of the current script to load the loadingAnimation.gif animation +var src=document.getElementsByTagName('script'); +var src=src[src.length-1].getAttribute('src'); +// remove the inc/lib/javascript/thickbox.js part (30 characters) +var src=src.substr(0,src.length-30); +var tb_pathToImage = src+"img/loadingAnimation.gif"; /*!!!!!!!!!!!!!!!!! edit below this line at your own risk !!!!!!!!!!!!!!!!!!!!!!!*/