Tell a friend,

liunx

Guest
<body><br />
<script language="JavaScript1.2"><br />
<!--<br />
function dothis(_f)<br />
{<br />
var _e=_f.ename.value;<br />
var _s=_f.subj.value?"?subject="+_f.subj.value:"";<br />
var _b=_f.bod.value?"body="+_f.bod.value:"";<br />
if(_s&&_b) _b="&"+_b; else if(_b)_b="?"+_b;<br />
if(_e)<br />
document.location="mailto:"+_e+_s+_b;<br />
return _e?true:false;<br />
}<br />
//--><br />
</script><br />
<br />
<br />
</head><br />
<body><br />
Email to: <input type="text" name="ename" size="20"><br />
Subject: <input type="text" name="subj" size="20"><br />
<br />
<br />
<input type="button" value="Send URL to a Friend" onclick="dothis(this.form)"><br />
<input type="reset" value="Clear text"><br />
</form><font><br />
<br />
</body><br />
</html><br />
<br />
I want the box empty for a person to type in a freinds email address, stuck in the code of the URL to send, is it also an input?<!--content-->You need a third text box for the body part of the mail.But you can make it invicible to the users by making it as a hidden field.YOu can give whatever message you want and the url in the hidden text box.<br />
<br />
If you want you can make the third text box visible by changing the input type from "hidden" to "text".<br />
<br />
Checkout the attachment.<!--content-->
 
Back
Top