Nieuw lid |
|
Ik gebruik onderstaande code, op meerdere plaatsen in mijn website bij de formulieren. Helaas gaat dit niet altijd goed. Op het ene punt werkt het prima en kun je met je muis over het vraagteken gaan en dan krijg je netjes de uitleg te zien, maar de andere keer gebeurt er niets. Weet iemand misschien, wat ik fout doe?
<td><a style="cursor: hand;"
onMouseOver="showDetails('popup10',null,null)"
onMouseOut="startTimer(this)"><img src="img/icons/help2_ico.gif" alt="" width="16" height="16" hspace="3" border="0"></a><TABLE BGCOLOR="#FFFF99" Width="90" CLASS="tooltip"
ONMOUSEOVER="stopTimer()" ONMOUSEOUT="startTimer(this)" BORDER=0 ID="popup10" STYLE="border:1px gray solid;" cellpadding="1" cellspacing="1"><TR><td
CLASS="tooltiptxt">Tekst<td></TR></TABLE></td>
<td><a style="cursor: hand;" onMouseOver="showDetails('popup10',null,null)" onMouseOut="startTimer(this)"><img src="img/icons/help2_ico.gif" alt="" width="16" height="16" hspace="3" border="0"></a><TABLE BGCOLOR="#FFFF99" Width="90" CLASS="tooltip" ONMOUSEOVER="stopTimer()" ONMOUSEOUT="startTimer(this)" BORDER=0 ID="popup10" STYLE="border:1px gray solid;" cellpadding="1" cellspacing="1"><TR><td CLASS="tooltiptxt">Tekst<td></TR></TABLE></td>
<SCRIPT>
<!--
// Copyright 1999 InsideDHTML.com, LLC. All rights reserved
// For more information see www.siteexperts.com
// This script can be reused as long as this copyright notice is maintained
var iDelay = 200
var sDisplayTimer = null, oLastItem
function getRealPos(i,which) {
iPos = 0
while (i!=null) {
iPos += i["offset" + which]
i = i.offsetParent
}
return iPos
}
function showDetails(sDest,itop,ileft) {
if (document.all) {
var i = event.srcElement
stopTimer()
dest = document.all[sDest]
if ((oLastItem!=null) && (oLastItem!=dest))
hideItem()
if (dest) {
if (ileft)
dest.style.pixelLeft = ileft
else
dest.style.pixelLeft = getRealPos(i,"Left") + i.offsetWidth + 5
if (itop)
dest.style.pixelTop = itop
else
dest.style.pixelTop = getRealPos(i,"Top")
dest.style.display = "block"
}
oLastItem = dest
}
}
function stopTimer() {
clearTimeout(sDisplayTimer)
}
function startTimer(el) {
if (!el.contains(event.toElement)) {
stopTimer()
sDisplayTimer = setTimeout("hideItem()",iDelay)
}
}
function hideItem() {
if (oLastItem)
oLastItem.style.display="none"
}
//-->
</SCRIPT>
<SCRIPT> <!-- // Copyright 1999 InsideDHTML.com, LLC. All rights reserved // For more information see www.siteexperts.com // This script can be reused as long as this copyright notice is maintained var iDelay = 200 var sDisplayTimer = null, oLastItem function getRealPos(i,which) { iPos = 0 while (i!=null) { iPos += i["offset" + which] i = i.offsetParent } return iPos } function showDetails(sDest,itop,ileft) { if (document.all) { var i = event.srcElement stopTimer() dest = document.all[sDest] if ((oLastItem!=null) && (oLastItem!=dest)) hideItem() if (dest) { if (ileft) dest.style.pixelLeft = ileft else dest.style.pixelLeft = getRealPos(i,"Left") + i.offsetWidth + 5 if (itop) dest.style.pixelTop = itop else dest.style.pixelTop = getRealPos(i,"Top") dest.style.display = "block" } oLastItem = dest } } function stopTimer() { clearTimeout(sDisplayTimer) } function startTimer(el) { if (!el.contains(event.toElement)) { stopTimer() sDisplayTimer = setTimeout("hideItem()",iDelay) } } function hideItem() { if (oLastItem) oLastItem.style.display="none" } //--> </SCRIPT>
|