Welcome! Log In Create A New Profile


Code Question About Links

Posted by selym 
Code Question About Links
January 15, 2009 07:35PM
Hey all-

Does anyone know how I could make it so when I hover over a search result link that the domain name only shows up in the lower left corner of the screen? I've seen it on a different search engine (non-sphider) and I thought it was great. You would hover over a link and it would show www.anydomain.com instead of something like www.anydomain.com/index.php?somethinghere&somethingelse/01152008/blahblah, etc.

Any ideas? Would that be CSS?


Re: Code Question About Links
January 16, 2009 06:55PM
You would probably have to bind a mouseover event listener to all the anchor tags, and have it override the status bar message with the domain, something like the following (not tested):

<a href="http://www.domain.com/a/b/c.html" onmouseover="status='http://www.domain.com'; return true;" ...

The bad news is that most modern browsers no longer allow status bar message changing (due to abuse in tricking people into clicking bogus links), and I don't know of any workarounds. SOmeone else may have a better idea.

Edited 1 time(s). Last edit at 01/16/2009 07:02PM by mikez.
Sorry, only registered users may post in this forum.

Click here to login