...

View Full Version : Editing Status bar when mouseover link



KyuubiKahiera
09-24-2006, 04:30 AM
like the title says, how do you edit what the status bar says when the crusor is over a link (basicaly like hiding the destination of the link - kinda ;D)

_Aerospace_Eng_
09-24-2006, 07:00 AM
Why would you do this? Hiding the url from the user isn't a good idea. Besides it won't work in Opera and Firefox allows users to not allow it.

theDragonsDen
09-24-2006, 04:21 PM
<span style="cursor: hand" onclick="location.href=http://thedragonsden.us.to'" onmouseover="window.status='theDragonsDen'" onmouseout="window.status=''">Click Here to Visit theDragon'sDen</span>

KyuubiKahiera
09-24-2006, 09:08 PM
<span style="cursor: hand" onclick="location.href=http://thedragonsden.us.to'" onmouseover="window.status='theDragonsDen'" onmouseout="window.status=''">Click Here to Visit theDragon'sDen</span>

i tried this and it does show the edited statusbar but, when i click on the text, nothing happens

felgall
09-24-2006, 11:17 PM
Most browsers have the option to allow Javascript to update the status bar turned off. You can only update the status bar from Javascript where the person visiting your site has specifically turned on that option in their browser. They are u8nlikely to do that as that opens a number of security holes that can potentially result in their computer hard drive being trashed.

Arbitrator
09-25-2006, 02:14 AM
Besides it won't work in Opera [].Works fine for me in Opera 9.01. Of course, I may have tampered with the defaults and not remember having done so.


i tried this and it does show the edited statusbar but, when i click on the text, nothing happensThat's because the Javascript is missing an apostrophe within the onclick attribute's value. It's also using an incorrect, proprietary value for the cursor property; hand should be pointer. Here's a corrected version of theDragonsDen's code:


CSS:
span {
cursor: pointer;
color: red;
text-decoration: underline;
}

HTML and inline JavaScript/:
<span onclick="location.href='http://thedragonsden.us.to/';"
onmouseover="window.status='theDragon\u0027sDen';"
onmouseout="window.status='';">Click Here to Visit theDragon'sDen</span>Of course, I would advise using an anchor (a) element instead of a span element for the link so that you have a fall-back in case the user has JavaScript disabled:


<a href="http://thedragonsden.us.to/"
onmouseover="window.status='theDragon\u0027sDen';"
onmouseout="window.status='';">Click Here to Visit theDragon'sDen</a>

KyuubiKahiera
09-25-2006, 03:12 AM
CSS:
span {
cursor: pointer;
color: red;
text-decoration: underline;
}

HTML and inline JavaScript/:
<span onclick="location.href='http://thedragonsden.us.to/';"
onmouseover="window.status='theDragon\u0027sDen';"
onmouseout="window.status='';">Click Here to Visit theDragon'sDen</span>

this shows what i want done but i just need the text to be underlined and blue (which i can do myself) but, it shows the wrong crusor image i want. how can it be the pointer/finger crusor image?

_Aerospace_Eng_
09-25-2006, 05:35 AM
Just use the link code he gave you. It will get the finger cursor by default.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum