Link to home
Start Free TrialLog in
Avatar of renesisx
renesisx

asked on

IE Hover bug. Fix without hash (pound sign) in href?

IE only allows the hover property on anchor (<a href..>) tags.

The problem with the anchor tags is that they need a value in the "href" attribute.

Historically this is set to "#", which is essentially a "do nothing" link.

My problem is that the page jumps up as the user clicks on that link. I don't want that, as the link just activates an AJAX effect on the page.

I also tried setting the href to simply "javascript:;" to see if that would work, but nothing.

Any ideas for a solution to this?
Avatar of renesisx
renesisx

ASKER

Oh, and I also tried setting the onclick attribute to "javascript:return false;" which didn't help either.

Plus I tried an anchor tag that didn't have a href, but just an "id". The hover tag didn't work at all then.
ASKER CERTIFIED SOLUTION
Avatar of hongjun
hongjun
Flag of Singapore image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Put the return false on onclick event
Damn, just needed me to remove the "javascript:" from the onclick.

Thanks :)