Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Script Help

Status
Not open for further replies.

stevanb

Technical User
Oct 4, 2002
58
US
When using the send mail script I use for email off my site where do i insert the check script
Like i have it here or do i have to change some thing

Thxs STeve


<form action=&quot; method=&quot;POST&quot;>
<input type=hidden name=&quot;to&quot; value=&quot;info@cruisewarehouse.cc&quot;>
<input type=hidden name=&quot;redir&quot;
value=&quot;
<form name=&quot;validation&quot; onSubmit=&quot;return checkbae()&quot;>
Please input a valid email address:<br>
<input type=&quot;text&quot; size=18 name=&quot;emailcheck&quot;>
<input type=&quot;submit&quot; value=&quot;Submit&quot;>
</form>
<script language=&quot;JavaScript1.2&quot;>

var testresults
function checkemail(){
var str=document.validation.emailcheck.value
var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i
if (filter.test(str))
testresults=true
else{
alert(&quot;Please input a valid email address!&quot;)
testresults=false
}
return (testresults)
}
</script>

<script>
function checkbae(){
if (document.layers||document.getElementById||document.all)
return checkemail()
else
return true
}
</script>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top