[thelist] IE5 with href and onclick problem?

Lee kowalkowski lee.kowalkowski at googlemail.com
Thu Jun 8 02:58:13 CDT 2006


On 07/06/06, Stefan Schwarzer <st.schwarzer at geois.de> wrote:
> Hi there,
>
> just run through some testing, and discovered some strange behavior
> with IE5.
>
> Until now everything worked well when I used the following command:
>
>        <a href="#" onclick="sendForm('23');" class="whitearrowright">next</a>
>
> But IE5 didn't seem to accept the "onclick" event for the link. It
> does work like this:
>
>        <a href="javascript: sendForm('23');" class="whitearrowright">next</a>
>
> I guess this is because the onlick event for the a-tag hasn't been
> implemented in that version of the browser. Or am I doing something
> wrong?
>
> Thanks for any hints.

onclick events on links work in IE5, but in my private notes I have a
comment about not using "#" for href values at the same time as
submitting forms in JavaScript in early versions of IE.  Try
onclick="sendForm('23');return false;"

-- 
LK



More information about the thelist mailing list