[Reply To] RE: [thelist] dreamweaver pop up window code
Bj
list at plainweb.co.uk
Sat May 3 10:03:45 2003
----- Original Message -----
From: "Boldacious Web Design" <cf at boldacious.com
> Is there a way to hide a javascript close window link from
> non-js browsers. Or actually more exactly - I want to have
> a close window link in the pop-up window but a back button
> in the normal page that will open up on non-js browsers.
You can't do a non-JS back button on the page because the only way a back
button can work is with JavaScript.
You can make the JS close link only appear if JS is enabled, by using a JS
document.write to put it into the page:
<script>
document.write('<a href="self.close;">Close window</a>');
</script>
and you can add anything that you want only non JS browsers to see by
enclosing it in <noscript> tags:
<noscript>
Please close the window
</noscript>
Only one of the above bits of code should display, the first if JS is
enabled and the second if not.
Bj
More information about the thelist
mailing list