javascript - onnouseover not working in chrome, was working until update -
javascript - onnouseover not working in chrome, was working until update -
i have next function beingness called via onmouseover on
function showtooltip(tip, el, evt) { if (document.layers) { if (!el.tip) { el.tip = new layer(200); el.tip.document.open(); el.tip.document.write(tip); el.tip.document.close(); el.onclick = function (evt) { this.tip.visibility = 'hide'; }; el.onmouseout = function (evt) { this.tip.visibility = 'hide'; }; } el.tip.left = evt.pagex; el.tip.top = evt.pagey; el.tip.visibility = 'show'; } else if (document.all) { if (!el.tip) { document.body.insertadjacenthtml('beforeend', '<div id="tip' + tc + '" class="tooltip">' + tip + '<\/div>'); el.tip = document.all['tip' + tc++]; el.onclick = function (evt) { this.tip.style.visibility = 'hidden'; }; el.onmouseout = function (evt) { this.tip.style.visibility = 'hidden'; }; } el.tip.style.pixelleft = event.clientx + document.body.scrollleft - 200 el.tip.style.pixeltop = event.clienty + document.body.scrolltop + 10 el.tip.style.visibility = 'visible'; } }
the phone call looks like;
<img id="contentplaceholder1_documentlist1_dg_imgnotes_0" onmouseover="javascript:showtooltip('<b>pages:</b> 1<br><b>date:</b> 8/7/2014<br><b>rep id:</b> 789',this,event);" src="/applications/images/icons/no-a.bmp" align="absmiddle" style="border-width:0px;">
with event of;
onmouseover="javascript:showtooltip('<b>pages:</b> 1<br><b>date:</b> 8/7/2014<br><b>rep id:</b> 789',this,event);"
this code has been working without hitch upwards of year , still functions correctly in firefox , ie, not chrome version 38.0.2125.111 m. no expert, sense declarations fine , info beingness passed alright, when hits function steps on if(document.layers) , else if(document.all) when debugging, however, when in ie , debugging steps else if statement find , renders tooltip exact same site.
any help appreciated.
document.all
, document.layers
obsolete. no longer supported chrome.
javascript google-chrome onmouseover
Comments
Post a Comment