I agree with you (I also have to point out that I wrote about using the
onError event October 25th). :-)
/Robert
-----Ursprungligt meddelande-----
Fr=E5n: Teng-Fong SEAK [mailto:tfseak@f...]
Skickat: den 29 oktober 2002 11:00
Till: javascript
=C4mne: [javascript] Re: SV: Checking if Img src exists
Maybe it's a problem of downloading time : the code is executed before
the image is completely loaded.
onerror seems to be a more appropriate choice, IMO, because it's up to
the browser to determine if there's error or not after a timeout.
Moreover, onerror is standard in DOM2 whereas I can't find any reference
of complete in DOM1&2 (correct me if I'm wrong) even though complete was
implemented in JS 1.1.
> -----Message d'origine-----
> De : Louise Greally [mailto:lou_greally@h...]
> Envoy=E9 : mardi 29 octobre 2002 07:23
> =C0 : javascript
> Objet : [javascript] Re: SV: Checking if Img src exists
>
>
> yes it works most of the time. sometimes when i first run the code it
> doesnt work until i run it again. i.e. I run the code on the onchange
> event of some fields and sometimes it only works if I change
> the field a
> couple of times first?? although the function is running the
> code just not
> running that bit of code??
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=3Dnosim/theprogramm
e
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=3Dnosim/theprogramm
e
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=3Dnosim/theprogramm
e
r-20