Ok I think this is what you want it to do.
Put this in the head section of your page or a js file and link to it.
Code:
<script language="javascript">
<!--
var state = 'hidden';
function showhide(layer_ref) {
if (state == 'visible') {
state = 'hidden';
}
else {
state = 'visible';
}
if (document.all) { //IS IE 4 or 5 (or 6 beta)
eval( "document.all." + layer_ref + ".style.visibility = state");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers[layer_ref].visibility = state;
}
if (document.getElementById && !document.all) {
hiddencode = document.getElementById(layer_ref);
hiddencode.style.visibility = state;
}
}
//-->
</script>
And this is the code to show the coupon code and open a site (godaddy in this example) in another window (IE) or tab (FF)
Code:
<a onclick="showhide('coupon_code'),window.open('http://www.godaddy.com','popup');return false;">-->>click here<<--</a> to see the coupon code!
<!-- START - HIDDEN INFORMATION TO BE SHOWN ONCLICK -->
<div id="coupon_code" style="visibility:hidden;">
<strong>Coupon Code</strong>
</div>
<!-- END - HIDDEN INFORMATION TO BE SHOWN ONCLICK -->
I put this together from various sources.
You'll need to work on the link style as it isn't a visible link as it is now so if you style it with blue and an underline it would appear as a link.
Hope it helps or at least puts you on the right path to find what you need.
Aus
Bookmarks