I have source code for a popup calendar that works fine in IE6 but not in Mozilla and I am at a loss as to why this is:
I get the error
crossobj has no properties (Line 304) in the Javascript console; this line translates to
crossobj.visibility = 'hidden';
Now, upon tracing it back it seems like this is all the applicable code:
var ie = document.all;
var dom = document.getElementById;
........
........
document.write ('<div onclick="bShow=true" id="calendar" style="z-index:+999;...') etc etc (the calendar id gets rendered here)
.....
function init(){
crossobj=(dom)?document.getElementById('calendar').style: ie? document.all.calendar : window.document.getElementById('calendar');
.....
}
.....
window.onload=init
......
Does anyone know why this would work in IE but not in Mozilla? I know that Mozilla handles window events differently, but how would that apply here? Any help would be greatly appreciated.
I get the error
crossobj has no properties (Line 304) in the Javascript console; this line translates to
crossobj.visibility = 'hidden';
Now, upon tracing it back it seems like this is all the applicable code:
var ie = document.all;
var dom = document.getElementById;
........
........
document.write ('<div onclick="bShow=true" id="calendar" style="z-index:+999;...') etc etc (the calendar id gets rendered here)
.....
function init(){
crossobj=(dom)?document.getElementById('calendar').style: ie? document.all.calendar : window.document.getElementById('calendar');
.....
}
.....
window.onload=init
......
Does anyone know why this would work in IE but not in Mozilla? I know that Mozilla handles window events differently, but how would that apply here? Any help would be greatly appreciated.