I have a web app that you can choose to click items out of the side bar, and it retrieves the contents and displays a popup when you click them in chrome, and it also works in firefox with firebug enabled, but not when its disable. it just uses onclick in the div tag. Not only that but it seemingly doesn't work for only one kind of the items. The rest work fine.
Asked
Active
Viewed 370 times
0
-
1You should post some code, but it sounds to me like aor something is not being closed. Firebug adds some elements to the bottom of the page, IIRC, and maybe that helps the DOM cleanup in FF figure out the missing tag.– nc. Jan 05 '11 at 01:59
2 Answers
1
Your code is probably calling console.log
.
In Firefox, the console
object will only exist when Firebug is open.
To fix this, you can write
if (!window.console)
console = { log: function() { } };

SLaks
- 868,454
- 176
- 1,908
- 1,964
1
Check out this similar question. 'console' is undefined error for Internet Explorer. I discovered today that IE will not recognize if(!console) by itself since console is considered part of the window object.
I had to use:
if (!window.console)
console = { log: function() { } };

Community
- 1
- 1

jamesmortensen
- 33,636
- 11
- 99
- 120