Hide status bar link

I

Ian Shere

I have a disclaimer page prior to a visitor going to my FAQ page. I want to
hide the link which normally appears in the status bar from visitors seeing
it.

I am using the following code which works fine except that the "I Agree"
link still shows the link path. What's wrong - driving me nuts!!??
<script language="JavaScript">

<!-- Hide the script from old browsers --

function a(txt) {

self.status = txt

}

function b() {

self.status = ""

}

// --End Hiding Here -->

</script>

<A HREF="index.html" onMouseOver="a('Return to Home Page');return true"

onMouseOut="window.status=''; ">I Disagree</a>

<p>

<A HREF="freqquest.html" onMouseOver="a('Go to FAQ's Page');return true"

onMouseOut="window.status=''; ">I Agree</a>
 
V

VK

window.status="..."; return true;

To activate the status change, you always have to return the true.
It comes from NN v2 prehistory, and it has no sense or use anymore, but
ECMA keeps it for some reason (nostalgia?).
 
I

Ian Shere

Not sure exactly where that's to go - I copied it to where it seemed it
should be and nothing worked at all. So I am back to where I started with
the 2nd link path ALWAYS showing in the status bar and the first nicely
displaying my message.
 
I

Ian Shere

Figured it out! It was in this piece of code - onMouseOver="a('Go to FAQ's
Page');return true. JS was reading the ' in FAQ's as the end of that
portion of text and then didn't know what to do with 's - I just didn't
notice the error message in the status bar!
 
D

David Dorward

Ian said:
I have a disclaimer page prior to a visitor going to my FAQ page. I want
to hide the link which normally appears in the status bar from visitors
seeing it.

Rule 1: If you hide something from the user, you are going to annoy people.
Rule 2: If you hide something from the user with JavaScript, its likely to
be trivial to unhide it

(and I love Mozilla's "Allow Scripts to: [] Change status bar text" option)

Security thorough obscurity is not security:
http://www.tbray.org/ongoing/When/200x/2003/12/17/LegalInsecurity

(and click through agreements are worthless anyway)
 
K

kaeli

(and I love Mozilla's "Allow Scripts to: [] Change status bar text" option)

You're not the only one. :)

I HATE when people change my status bar.

And in IE, if I really care, I can get the properties of the link to see
where it goes. Last resort I can view the source of the page.

--
 
I

Ian Shere

Trivial for anyone who know JS yes - that accounts for a very small %age of
net users.
Second, hiding a link from appearing in the status bar is highly unlikely to
annoy any but a minute number of users.
Third, a click through agreement beats nothing at all, and certainly in
court here, would be VERY useful.

--
Ian Shere
Tarzan Design Ltd
Award Winning Architecture
www.tarzandesign.co.nz
David Dorward said:
Ian said:
I have a disclaimer page prior to a visitor going to my FAQ page. I want
to hide the link which normally appears in the status bar from visitors
seeing it.

Rule 1: If you hide something from the user, you are going to annoy people.
Rule 2: If you hide something from the user with JavaScript, its likely to
be trivial to unhide it

(and I love Mozilla's "Allow Scripts to: [] Change status bar text" option)

Security thorough obscurity is not security:
http://www.tbray.org/ongoing/When/200x/2003/12/17/LegalInsecurity

(and click through agreements are worthless anyway)
 
D

David Dorward

Ian Shere wrote:

Please read: http://www.allmyfaqs.com/faq.pl?How_to_post
Trivial for anyone who know JS yes - that accounts for a very small %age
of net users.

Or who don't know JS but know how to turn it off
or look at the HTML source
or right click and copy link location
or ...
Second, hiding a link from appearing in the status bar is highly unlikely
to annoy any but a minute number of users.

But a much larger proportion of users who bother to look at the status bar
Third, a click through agreement beats nothing at all, and certainly in
court here, would be VERY useful.

I'm not an expert in this field, but I find it highly doubtful that it will.
How do you prove they clicked through?
 
@

@SM

Ian Shere a ecrit :
Figured it out! It was in this piece of code - onMouseOver="a('Go to FAQ's
Page');return true. JS was reading the ' in FAQ's as the end of that
portion of text and then didn't know what to do with 's - I just didn't
notice the error message in the status bar!

You have to use \' insteed of '

<A HREF="freqquest.html" onMouseOver="a('Go to FAQ\'s Page');return true"
onMouseOut="window.status=''; return true;">I Agree</a>

onmouseover
and
onmouseout
! !

==== how to use window.status =====

<script type="text/JavaScript"><!--

// default status message
stat = "My so pretty home page on Net";
// default status (NN)
defaultStatus = stat;
// not clever browsers with default status
ie = (document.all || document.getElementById);
// special function to get back default message (not for NN)
function b() { if(ie) {window.status = stat; return true;} }
// to display a message in status bar
function a(txt) { window.status = txt; }
// launch default status (on IE)
onload = b;

// --></script>

<A HREF="freqquest.html" onmouseover="a('Go to FAQ\'s Page');return true;"
onmouseout="b();">I Agree</a>
 
T

Thomas 'PointedEars' Lahn

VK said:
window.status="..."; return true;

To activate the status change,

which one does not really want
you always have to return the true.
It comes from NN v2 prehistory, and it has no sense or use anymore, but
ECMA keeps it for some reason (nostalgia?).

What are you talking about? There is no `status'
property in ECMAScript as `window' is a host object.


PointedEars
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top