Nexus
18-Mar-2011, 09:28 PM
Hi,
I've set up formmail and everything is working, I receive an email with the forms details and get the thank you reply back.
The problems I have is that the form does is not being validated at the client end, there is no form checking to see if it's a valid email address that has been entered or if the required fields are filled out. Should there not be some kind of onsubmit call to a function within formval.js?
Currently the contact.htm and the formval.js are residing in the same directory and the paths are correct.
I've included the top part of the contact form here:
----------
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<style type="text/css">
@import url(formdesigneruser.css);
</style>
<script type="text/javascript" src="formval.js"></script>
</head>
<body>
<form id="Contact" name="Contact" method="post" action="http://MYWEBSITE HERE REMOVED/formmail.php">
<div class="TectiteFormDesignerField">
---------
Any assistance would be great as currently without the client side validation of the form it's not of much use.
My grateful thanks in advance.
Richard
UPDATE:
I now get a message 'Please enter a value for this field' should I not put anything in the field which is great, so all I seem to be missing is a check to see if it is a valid email address, i.e. contains an @. Perhaps, this javascript does not check for this, can anyone confirm this?
I've set up formmail and everything is working, I receive an email with the forms details and get the thank you reply back.
The problems I have is that the form does is not being validated at the client end, there is no form checking to see if it's a valid email address that has been entered or if the required fields are filled out. Should there not be some kind of onsubmit call to a function within formval.js?
Currently the contact.htm and the formval.js are residing in the same directory and the paths are correct.
I've included the top part of the contact form here:
----------
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<style type="text/css">
@import url(formdesigneruser.css);
</style>
<script type="text/javascript" src="formval.js"></script>
</head>
<body>
<form id="Contact" name="Contact" method="post" action="http://MYWEBSITE HERE REMOVED/formmail.php">
<div class="TectiteFormDesignerField">
---------
Any assistance would be great as currently without the client side validation of the form it's not of much use.
My grateful thanks in advance.
Richard
UPDATE:
I now get a message 'Please enter a value for this field' should I not put anything in the field which is great, so all I seem to be missing is a check to see if it is a valid email address, i.e. contains an @. Perhaps, this javascript does not check for this, can anyone confirm this?