Hi, I've got some very old JavaScript code on a very important page that I think is messing up my Mac users... This is the code:
<script language="JavaScript1.2">
var testresults
function checkemail(){
var str=document.validation.semail.value
var filter=/^.+@.+\..{2,3}$/
if (filter.test(str))
testresults=true
else{
alert("Please input a valid email address!")
testresults=false
}
return (testresults)
}
</script>
<script>
function checkbae(){
if (document.layers||document.all)
return checkemail()
else
return true
}
</script>
On occasion, I get a client that calls me and says, my email is <!-- e --><a href="mailto:[email protected]">[email protected]</a><!-- e --> and your page is showing me a pop-up.
Is there something wrong with the code by today's standards?
Thanks you kindly for the help,
Pete
FYI: 'semail' is the name of the form within the html for the email address. But I'm sure you folks figured that out just by looking at the code -- I'm such a newbie.
<script language="JavaScript1.2">
var testresults
function checkemail(){
var str=document.validation.semail.value
var filter=/^.+@.+\..{2,3}$/
if (filter.test(str))
testresults=true
else{
alert("Please input a valid email address!")
testresults=false
}
return (testresults)
}
</script>
<script>
function checkbae(){
if (document.layers||document.all)
return checkemail()
else
return true
}
</script>
On occasion, I get a client that calls me and says, my email is <!-- e --><a href="mailto:[email protected]">[email protected]</a><!-- e --> and your page is showing me a pop-up.
Is there something wrong with the code by today's standards?
Thanks you kindly for the help,
Pete
FYI: 'semail' is the name of the form within the html for the email address. But I'm sure you folks figured that out just by looking at the code -- I'm such a newbie.