jnbits
05-22-2007, 12:43 PM
Hi
I have asked this Web Design Company to design this form for my contact page on my website but i don't no how they work.
This is the html of the contact form but it dose not work when i try it my self and i don't no why it don't work and never do the web design company.
Please can someone help me. :help:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script language="JavaScript">
<!--
function SymError()
{
return true;
}
window.onerror = SymError;
var SymRealWinOpen = window.open;
function SymWinOpen(url, name, attributes)
{
return (new Object());
}
window.open = SymWinOpen;
//-->
</script>
<SCRIPT LANGUAGE="JavaScript">
<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->
<!-- Begin
function getCookie(name){
var cname = name + "=";
var dc = document.cookie;
if (dc.length > 0) {
begin = dc.indexOf(cname);
if (begin != -1) {
begin += cname.length;
end = dc.indexOf(";", begin);
if (end == -1) end = dc.length;
return unescape(dc.substring(begin, end));
}
}
return null;
}
function setCookie(name, value) {
var now = new Date();
var then = new Date(now.getTime() + 31536000000);
document.cookie = name + "=" + escape(value) + "; expires=" + then.toGMTString() + "; path=/";
}
function getInfo(form) {
form.info.value = "Browser Information: " + navigator.userAgent;
}
function getValue(element) {
var value = getCookie(element.name);
if (value != null) element.value = value;
}
function setValue(element) {
setCookie(element.name, element.value);
}
function fixElement(element, message) {
alert(message);
element.focus();
}
function isMailReady(form) {
var passed = false;
if (form.fullname.value == "") {
fixElement(form.fullname, "Please include your name.");
}
else if (form.email.value.indexOf("@") == -1 ||
form.email.value.indexOf(".") == -1) {
fixElement(form.email, "Please include a proper email address.");
}
else if (form.telephone.value == "") {
fixElement(form.telephone, "Please include a telephone number.");
}
else {
getInfo(form);
passed = true;
}
return passed;
}
// End -->
function addActionTest(theForm) {
if (theForm.subject.value != '') {
theForm.action += theForm.subject.value;
return true;
}
else { alert('Error'); return false;}
}
</SCRIPT>
</head>
<body>
<p align="center"><form name="contact form" method="post" action="mailto:sales@jnbits.co.uk" >
<p align="left" style="text-align: center">
Your Full Name:
<input type="text" size="40" name="fullname" onFocus = "getValue(this)" onBlur = "setValue(this)"/>
<br/>
Your Email Address:
<input type="text" size="40" name="email" onFocus = "getValue(this)" onBlur = "setValue(this)"/>
<br>
Telephone Number:
<input type="text" name="telephone" onFocus = "getValue(this)" onBlur = "setValue(this)">
<br>
Question Type:
<select name="subject" >
<option>Sales</option>
<option>Support</option>
<option>Newsletter</option>
</select>
</p>
</p>
<h3>Comments<br />
<textarea name="Comments" cols="36" rows="12" id="Comments"></textarea>
</h3>
<p style="text-align: center">Discount Code:
<input type="text" name="textfield">
</p>
<p style="text-align: center"><strong><font size="4">Ordering</font></strong></p>
<p style="text-align: center">Have you ordered from us before?
<input name="ordered?" type="radio" value="I have Before">
<br>
I will order from you one day
<input name="ordered?" type="radio" value="I will One Day" checked>
<br>
I wont order from you at all
<input name="ordered?" type="radio" value="I Never Will">
</p>
<p style="text-align: center"><font size="4">Feedback</font></p>
<p style="text-align: center">
<select name="select2">
<option>Excellent</option>
<option>Very Good</option>
<option>Good</option>
<option>Fair</option>
<option>Very Bad</option>
</select>
</p>
<p style="text-align: center"><br />
<br/>
<input value="Submit Form" type="submit" />
<input type="reset" name="Reset" value="Clear Form" />
</p>
</body>
</html>
<script language="JavaScript">
<!--
var SymRealOnLoad;
var SymRealOnUnload;
function SymOnUnload()
{
window.open = SymWinOpen;
if(SymRealOnUnload != null)
SymRealOnUnload();
}
function SymOnLoad()
{
if(SymRealOnLoad != null)
SymRealOnLoad();
window.open = SymRealWinOpen;
SymRealOnUnload = window.onunload;
window.onunload = SymOnUnload;
}
SymRealOnLoad = window.onload;
window.onload = SymOnLoad;
//-->
</script>
I have asked this Web Design Company to design this form for my contact page on my website but i don't no how they work.
This is the html of the contact form but it dose not work when i try it my self and i don't no why it don't work and never do the web design company.
Please can someone help me. :help:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script language="JavaScript">
<!--
function SymError()
{
return true;
}
window.onerror = SymError;
var SymRealWinOpen = window.open;
function SymWinOpen(url, name, attributes)
{
return (new Object());
}
window.open = SymWinOpen;
//-->
</script>
<SCRIPT LANGUAGE="JavaScript">
<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->
<!-- Begin
function getCookie(name){
var cname = name + "=";
var dc = document.cookie;
if (dc.length > 0) {
begin = dc.indexOf(cname);
if (begin != -1) {
begin += cname.length;
end = dc.indexOf(";", begin);
if (end == -1) end = dc.length;
return unescape(dc.substring(begin, end));
}
}
return null;
}
function setCookie(name, value) {
var now = new Date();
var then = new Date(now.getTime() + 31536000000);
document.cookie = name + "=" + escape(value) + "; expires=" + then.toGMTString() + "; path=/";
}
function getInfo(form) {
form.info.value = "Browser Information: " + navigator.userAgent;
}
function getValue(element) {
var value = getCookie(element.name);
if (value != null) element.value = value;
}
function setValue(element) {
setCookie(element.name, element.value);
}
function fixElement(element, message) {
alert(message);
element.focus();
}
function isMailReady(form) {
var passed = false;
if (form.fullname.value == "") {
fixElement(form.fullname, "Please include your name.");
}
else if (form.email.value.indexOf("@") == -1 ||
form.email.value.indexOf(".") == -1) {
fixElement(form.email, "Please include a proper email address.");
}
else if (form.telephone.value == "") {
fixElement(form.telephone, "Please include a telephone number.");
}
else {
getInfo(form);
passed = true;
}
return passed;
}
// End -->
function addActionTest(theForm) {
if (theForm.subject.value != '') {
theForm.action += theForm.subject.value;
return true;
}
else { alert('Error'); return false;}
}
</SCRIPT>
</head>
<body>
<p align="center"><form name="contact form" method="post" action="mailto:sales@jnbits.co.uk" >
<p align="left" style="text-align: center">
Your Full Name:
<input type="text" size="40" name="fullname" onFocus = "getValue(this)" onBlur = "setValue(this)"/>
<br/>
Your Email Address:
<input type="text" size="40" name="email" onFocus = "getValue(this)" onBlur = "setValue(this)"/>
<br>
Telephone Number:
<input type="text" name="telephone" onFocus = "getValue(this)" onBlur = "setValue(this)">
<br>
Question Type:
<select name="subject" >
<option>Sales</option>
<option>Support</option>
<option>Newsletter</option>
</select>
</p>
</p>
<h3>Comments<br />
<textarea name="Comments" cols="36" rows="12" id="Comments"></textarea>
</h3>
<p style="text-align: center">Discount Code:
<input type="text" name="textfield">
</p>
<p style="text-align: center"><strong><font size="4">Ordering</font></strong></p>
<p style="text-align: center">Have you ordered from us before?
<input name="ordered?" type="radio" value="I have Before">
<br>
I will order from you one day
<input name="ordered?" type="radio" value="I will One Day" checked>
<br>
I wont order from you at all
<input name="ordered?" type="radio" value="I Never Will">
</p>
<p style="text-align: center"><font size="4">Feedback</font></p>
<p style="text-align: center">
<select name="select2">
<option>Excellent</option>
<option>Very Good</option>
<option>Good</option>
<option>Fair</option>
<option>Very Bad</option>
</select>
</p>
<p style="text-align: center"><br />
<br/>
<input value="Submit Form" type="submit" />
<input type="reset" name="Reset" value="Clear Form" />
</p>
</body>
</html>
<script language="JavaScript">
<!--
var SymRealOnLoad;
var SymRealOnUnload;
function SymOnUnload()
{
window.open = SymWinOpen;
if(SymRealOnUnload != null)
SymRealOnUnload();
}
function SymOnLoad()
{
if(SymRealOnLoad != null)
SymRealOnLoad();
window.open = SymRealWinOpen;
SymRealOnUnload = window.onunload;
window.onunload = SymOnUnload;
}
SymRealOnLoad = window.onload;
window.onload = SymOnLoad;
//-->
</script>