On click of an anchor tag i'm calling a javascript function.
In the function I'm using e.preventDefault and e.stopPropagation. After this the anchor tag becomes unclickable.

Any ideas?
LVL 20
Obadiah ChristopherAsked:
Who is Participating?
Obadiah ChristopherConnect With a Mentor Author Commented:
Ok. I'm not sure why this is happening. But this thing works on production environment.
Sorry I can't paste the code here.
What I'm trying to do is. I developed an ajax control that inherits from the AjaxModalPopup Extender control.

In IE6. it happens that any dropdowns beneath the modal get hidden. So I had to use e.preventDefault and e.stopPropagation
Gurvinder Pal SinghCommented:
<<In the function I'm using e.preventDefault and e.stopPropagation. After this the anchor tag becomes unclickable.>>
that is the whole idea,
when you do e.preventDefault it prevents the default behavior, which is making the anchor tag clickable
when you do e.stopPropagation, it prevents the event handling from propagating further.
Obadiah ChristopherAuthor Commented:
How does it work in FF and IE 7 then?
Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

Gurvinder Pal SinghCommented:
Don't think IE has e.preventDefault method.
Not sure why it is not working in FF

The link i have shared has an explanation
Hi, could you append your code?

It will help us to see what's the real problem.

it's not that it's becoming uncilckable, it is that the click action of the link has been modified to perform some javascript functionality instead of redirecting the browser.

As amischol says...code please!
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.