i'm confused... I thought that you couldn't have more than one header reference? I am on php 4.4.7 , I tried adding the header at the top and getting rid of the entire if statement and then adding to if and not at the top. both times I get an error saying that I already referenced header.
thanks for you help with this -
here is my new code:
<HTML>
<BODY>
<?php
//header('Location: http://www.crafterscafe.com/');
/ this page recieves and handles the date generated by contest.html./
//trim the incoming data
$Array["name"] = trim
($Array["name"]);
$Array["email"] = trim
($Array["email"]);
$Array["newsletter"] = trim
($Array["newsletter"]);
$Array["heard_about"] = trim
($Array["heard_about"]);
$Array["networking"] = trim
($Array["networking"]);
$Array["comments"] = trim
($Array["comments"]);
//set the variables for the database access:
$Host = "mysql.ixwebhosting.com";
$User = "smlwfar_pres";
$Password = "Contest09";
$DBName = "smlwfar_contest";
$TableName ="contesttwo";
$Link = mysql_connect ($Host, $User, $Password);
$Query="INSERT into $TableName values ('0', '$name', '$email', '$newsletter', '$heard_about', '$networking', '$comments')";
if (mysql_db_query($DBName, $Query, $Link)) {
//print ("The query was successfully executed!<br>\n");
header ("location: http://crafterscafe.com/store/index.php?main_page=page&id=9");
exit;
} else {
print ("The query could not be executed!<br>\n");
}
mysql_close ($Link);?>
</BODY></HTML>