Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap
irt.Org

Feedback: irt.org FAQ Knowledge Base Q120

Feedback on: irt.org FAQ Knowledge Base Q120

Sent by Bonnie on September 30, 1999 at 10:24:20: - feedback #489

Worth:
Very worth reading

Length:
Too long

Technical:
Too technical

Comments:
In response to the question, "Is it possible to highlight the text of a link using onMouseOver?", I've seen a apparently less complicated set of code, however, it only appears to work in IE 5. Is there any where to hook it up to a JavaScript function or access the NN DOM to get it to work in NN as well? Thanks!

<style>
A.on: {color:#FF00FF;
font-size: 12pt;
text-decoration: underline;}

A.off: {color:#0000CC;
font-size: 12pt;
text-decoration:none;}
</style>

and then, inside each link:

<a href="#whatever"
class="off"
onMouseOver="this.className='on'; return true"
onMouseOut="this.className='off'; ;return true">Some Text</a>







Sent by Russ G on November 18, 1999 at 07:02:15: - feedback #597

Worth:
Worth reading

Length:
Too long

Technical:
Too technical

Comments:
I had one once which used very little and when you put the mouse over the link, the link's background would change while on it until you moved away. Where can I get one like that, in about half the space of this one?


Sent by Mike on March 09, 2000 at 13:31:58: - feedback #912

Worth:
Very worth reading

Comments:
I want to simply thank you for this..

after hunting the net for 2.5 days
you provided me with just what I needed..

Thank you again
Mike


Sent by m.chung on July 21, 2000 at 00:15:43: - feedback #1517

Comments:
Don't work too well, sometimes it leaves items highlighted when you move over them real quick.

However, using zIndex rather than hide and show works :

function mover(object) {
if (ie4) {
eval(object + '.className = "highlight"');
} else if (ns4) {
eval('document.layers["' + object + 'b"].zIndex=0');
eval('document.layers["' + object + 'a"].zIndex=1');
}
}

function mout(object) {
if (ie4) {
eval(object + '.className = "normal"');
} else if (ns4) {
eval('document.layers["' + object + 'a"].zIndex=0');
eval('document.layers["' + object + 'b"].zIndex=1');
}
}

function dLink(href, text, oname) {
if (ie4) {
document.write('<A HREF="'+href+'" onMouseOut="mout(\'' + oname + '\')" onMouseOver="mover(\''+ oname +'\')" ID="' + oname + '" class="normal">'+text+'</A>');
} else if (ns4) {
document.write('<LAYER left="5" NAME="' + oname + 'a" z-index=0><A HREF="'+href+'" onMouseOut="mout(\'' + oname + '\')" onMouseOver="mover(\'' + oname + '\')" CLASS="highlight">'+text+'</A></LAYER><LAYER left="5" NAME="' + oname + 'b" z-index=1><A HREF="'+href+'" onMouseOut="mout(\'' + oname + '\')" onMouseOver="mover(\'' + oname + '\')" CLASS="normal">'+text+'<\A></LAYER>');
} else {
document.write('<A HREF="'+href+'">'+text+'</A>');
}
document.write('<BR>');
}



Sent by michel on July 26, 2001 at 03:03:36: - feedback #3009

Comments:
A problem is that netscape is unhappy when links with mouseovers/out are close together.. make sure there are some 5 pixels between and the script works better

Michel


©2018 Martin Webb