Bug #15225
closedJavascript Warning in Preload-Images because of uninitialized Variables
0%
Description
img9_0246_0_n=new Image(); img9_0246_0_n.src = "typo3temp/menu/282dff7f80.png";
img9_0246_0_h=new Image(); img9_0246_0_h.src = "typo3temp/menu/780d77cb38.png";
img14_8fcb_0_n=new Image(); img14_8fcb_0_n.src = "typo3temp/menu/ad9a9e6d69.png";
img14_8fcb_0_h=new Image(); img14_8fcb_0_h.src = "typo3temp/menu/8848231462.png";
it should be (just a "var" in front of the line):
var img9_0246_0_n=new Image(); img9_0246_0_n.src = "typo3temp/menu/282dff7f80.png";
var img9_0246_0_h=new Image(); img9_0246_0_h.src = "typo3temp/menu/780d77cb38.png";
var img14_8fcb_0_n=new Image(); img14_8fcb_0_n.src = "typo3temp/menu/ad9a9e6d69.png";
var img14_8fcb_0_h=new Image(); img14_8fcb_0_h.src = "typo3temp/menu/8848231462.png";
Patch is attached.
(issue imported from #M2061)
Files
Updated by Arne Bippes almost 19 years ago
Another case with uninitialized variables:
- browserName = navigator.appName;
- browserVer = parseInt(navigator.appVersion);
+ var browserName = navigator.appName;
+ var browserVer = parseInt(navigator.appVersion);
var msie4 = (browserName == "Microsoft Internet Explorer" && browserVer >= 4);
+ var version;
Updated by Not Only Pixel over 14 years ago
No Javascript errors where found in image menu.
Tested with: IE6-8, FF 1-3, Chrome 4, Safari