Click to See Complete Forum and Search --> : why wont it run in navigator?


danacton
05-01-2003, 12:49 PM
I used this widely available calendar in my web page and it is cool. I like the fact that you can select any month of any year and have the formatted month before you.

It works great in i.e., but doesn't seem to work in navigator at all. Is there a way that anyone knows - to make it work in navigator?

I don't know much about JavaScript - so thought I would ask the experts

Question 2: Someone suggested I do all my coding for my pages in navigator; just how many people out there are using navigator vs. i.e.

Any help would be greatly appreciated.


Dan

Oh yeah, the calendar is included in the attachment

gil davis
05-01-2003, 01:33 PM
Your problems stem from IE proprietary objects and properties. NS does not support "document.all" or "innerText".

If you want to code cross-browser for new versions (NS 6 and up), you can look into using document.getElementById() instead of document.all and innerHTML instead of innerText. IE 5+ will support both. Other than that, there aren't many differences between scripting for IE 5+ and NS 6+.

On the other hand, if you want to modify your code for NS 4, then you have a big job ahead of you.

danacton
05-02-2003, 12:06 AM
Hi Gil, and thanks for your help thus far...

I replaced all of the document.all with (document.getElementById) and the innerText with (innerHTML) throughout the entire script...

Since I hardly know what I'm doing, will you (or anyone) look at it again (updated version) and see why the calendar now will not work in either browser, that is: Nav.(7.0) or ie(6.0)

Dan

gil davis
05-02-2003, 07:28 AM
I have modified your calendar rather heavily, mostly because it seemed overly complicated to me. I think I have included all the features you originally had, and I have tested it using IE 5.5 and NS 6 (I don't have IE 6 or NS 7).

Let me know.

danacton
05-05-2003, 04:44 PM
Gil,


The calendar works perfectly and I was able to complete the job - with your help!


I can't thank you enough. I hope someday I can sort through code the way you have...


Much thanks again.


Dan