[thelist] javascript image replace broken in gecko

Tom Dell'Aringa pixelmech at yahoo.com
Fri Mar 7 13:00:00 CST 2003


--- danielEthan <daniel at ionize.net> wrote:

> Sure. Here's a spit out version of it (I don't have php on my ISP
> web space-- only locally). I've moved the javascript to be inline
> instead of linked. The StyleObject function is only used for the
> display properties, not for the image swapping though.
>
> http://www.ionize.net/temp.html

Daniel, the first thing I would do is read .jeff's excellent article
"Links & JavaScript Living Together in Harmony":

http://www.evolt.org/article/Links_and_JavaScript_Living_Together_in_Harmony/17/20938/index.html

Secondly, you should first fix the errors in your JS that are already
appearing. I am seeing at least an 'object expected' as well as
'return statement outside of function' in various places. (note: NS
is great for JS errors, type "javascript:" in the address bar after
you attempt something to see whats going on, it will give you great
error reporting).

I also find that if I strip out everything but the actual widget I am
working on in a separate page, it is much easier to work on. I would
put one menu on a single page with nothing else (no status message,
no nothing) and after reading that article, see what you come up with
and post back here.

Also, display should always have a value, either "block", "inline" or
"none", but not "".

Tom

=====
>^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
http://www.pixelmech.com/
var me = tom.pixelmech.webDeveloper();

http://www.maccaws.com/
[Making A Commercial Case for Adopting Web Standards]

__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/



More information about the thelist mailing list