In Android Browser link does not always execute onClick causing focus instead
- by Artem
I am trying to program a very standard JS behavior for a link using an HREF
onClick handler, and I am facing a strange problem caused by what I believe to be focus/touch mode behavior on Android.
Sometimes when I click on the link, instead of executing the action, it simply becomes selected/focused, with either just a focus rectangle or even also with a filled focus rectangle (selected as opposed to just focused?).
The pseudo-code right now is
<a href="#" onClick="toggleDivBelowToShowHide(); return false;">go</a>
I have tried doing something like:
<a href="#" onTouchStart="toggleDivBelowToShowHide(); return false;">go</a>
But I still get the same pesky problem some of the time.