问题
I have tried every which way to try to remove the heighlight when pushing on an image map area of an image. I have search google time and time again and have added all the CSS code i could find in hopes it would help.. but it does not seem to.
An example of what i am talking about:

I have added:
-webkit-user-modify: read-write-plaintext-only;
border:none;
outline: 0;
-webkit-tap-highlight-color: rgba(255, 255, 255, 0);
-khtml-user-select: none;
-o-user-select: none;
-moz-user-select: none;
-webkit-user-select: none;
user-select: none;
* {
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
cursor: none !important;
-webkit-user-modify: read-write-plaintext-only;
-khtml-user-select: none;
-o-user-select: none;
-moz-user-select: none;
-webkit-user-select: none;
user-select: none;
outline:none;
border: none;
}
img{
-khtml-user-select: none;
-o-user-select: none;
-moz-user-select: none;
-webkit-user-select: none;
user-select: none;
-webkit-user-modify: read-write-plaintext-only;
outline:none;
border: none;
border-style: none;
}
body, textarea:focus, input:focus, area:focus{
outline:none;
border: none;
-webkit-tap-highlight-color: rgba(255, 255, 255, 0);
-khtml-user-select: none;
-o-user-select: none;
-moz-user-select: none;
-webkit-user-select: none;
user-select: none;
-webkit-user-modify: read-write-plaintext-only;
}
a{
outline:none !important;
border: none !important;
}
a img
{
border:none;
outline:none;
}
area{
outline:none;
border: none;
-webkit-tap-highlight-color: rgba(255, 255, 255, 0);
-khtml-user-select: none;
-o-user-select: none;
-moz-user-select: none;
-webkit-user-select: none;
user-select: none;
-webkit-user-modify: read-write-plaintext-only;
}
#map {
outline:none;
border: none;
-webkit-tap-highlight-color: rgba(255, 255, 255, 0);
-khtml-user-select: none;
-o-user-select: none;
-moz-user-select: none;
-webkit-user-select: none;
user-select: none;
-webkit-user-modify: read-write-plaintext-only;
}
<img height="1024" src="img/MM.png" usemap="#MM_map" width="768" hidefocus="true">
<area coords="35,116,349,225" href="#HULU" id="HULU_id" onclick="$('#HULU').click();" shape="rect" style="border: none;" onfocus="blur();">
回答1:
The only way I could prevent that was by capturing the ontouchend event and preventing default browser behavior by returning false on the handler.
with jQuery:
$("map area").on("touchend", function() {
return false;
});
回答2:
Simple way. Proven. Used this again, just now even, in Android cordova app.
img[usemap], map area {
outline: none;
}
enjoy
来源:https://stackoverflow.com/questions/14131416/removing-heighlight-from-image-map-area-in-android-4-x-app-via-phonegap-build