[thelist] a href call for signup.pl

.jeff jeff at members.evolt.org
Thu Dec 19 04:31:01 CST 2002


> From: Russell Griechen
> <a href="#"
>    onClick="window.open('/cgi-bin/signup.pl',''
>   ,'height=300,width=400,status=no,scrollbars=no');">
>  Join Our Mailing List</a>

first, forget about using the hash as the value of the href attribute.
concentrate on making the link usable to anyone, with or without javascript,
first.  do that by moving the first argument of the open() method to the
href attribute.  then, in it's place put this.href which will make an object
reference (this) to the href attribute.  if you want a new window for
non-javascript users, be sure to add a target attribute with an appropriate
value.  finally, add a return false statement to the onclick event handler
so javascript capable browsers don't execute the link.

<a href="/cgi-bin/signup.pl"
   onclick="window.open(this.href, ''
 , 'height=300,width=400'); return false"
>Join Our Mailing Lists</a>

you'll notice that i ommitted the string "status=no,scrollbars=no" from the
third argument of the open() method.  i did that because ommission is the
same as setting those properties to no.


good luck,


jeff at members.evolt.org

More information about the thelist mailing list