I have this html code
<div>
<p>MY Text <a href="url">Text</a>
</p>
</div>
I need to use CSS or jQuery disable all A (link) elements in a DIV, when the user moves the mouse over the word: “Text”, I want the URL to be inactive so they can’t click on it. How do I do that?
To prevent an anchor from following the specified HREF, I would suggest using preventDefault():
See:
Event Objector