
blink359
Members-
Posts
169 -
Joined
-
Last visited
Never
Everything posted by blink359
-
My login script wont take my users to the restricted page and im not quite sure why it must be the header because it echos"wrong username or password" when i put in the wrong username or password here is my code: if($count==1 & $row['flight']=="vulcan"){ session_start(vmyusername); session_start(vmypassword); header("location:/vulcan/index.php"); }else if($count==1 & $row['flight']=="valiant"){ session_start(myusernamev); session_start(mypasswordv); header("location:valiant/index.php"); }else { echo "Wrong Username or Password"; } } ?> Any help would be much appriciated Thanks, Blink359
-
Hi there i have got my nav bar links but they are 5-10 pixels above the text that represents buttons but are really small i dont know why its only on google chrome/firfox/safari that its like it (so far) my website is http://valiantflight.comlu.com/261/index.php, take a look The code for the css is body { background-color: rgb(0, 84, 147); font-family: 'HelveticaNeue', 'Helvetica Neue', 'arial', sans-serif; margin-top:12px; font-size: 12px; position:relative; left:-10px; top:-2px; } #container { margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 10px; overflow: hidden; position: relative; word-wrap: break-word; background: #FFFFFF; text-align: left; width: 700px; } #navbar { float: right; padding-top: 8px; padding-bottom: 8px; padding-right:15px; } #navbar a { font-family: 'HelveticaNeue', 'Helvetica Neue', 'arial', sans-serif; font-size: 13px; font-weight:normal; color: #666666; text-decoration: none; font-weight:600; padding:8px; } #navbar a:hover { color: #999999; position: relative; } #navbarend { padding:0px; text-align: center; position:relative; left:1px; top:1px; } #footer { width: 700px; } #footerleft { padding-left:30px; float:left; overflow:hidden; } #footerright { float:right; padding-right:15px; display: inline; } #headertext { font-family: Verdana; font-size: 36px; text-align: left; font-weight:700; color: #005493; padding-top:6px; padding-left:20px; line-height: 44px; font-stretch: normal; font-style: normal; position:relative; top:-2px; left:1px; } #subheadertext { font-family: Verdana; font-size: 24px; font-weight:400; color: #005493; text-align: left; padding-top:0px; padding-left:25px; padding-bottom:50px; line-height: 29px; font-stretch: normal; font-style: normal; position:relative; left:1px; top:-1px; } #headerpic { float:right; padding-right:45px; padding-top:7px; padding-bottom:7px; position:relative; left:1px; } #header { width:700px; display:inline; } #mainpic { width:685px; height:223px; border-style:solid; border-color: #C0C0C0; border-top-width:10px; border-bottom-width:10px; border-left-width:8px; border-right-width:8px; background: url(../images/chromeheader.PNG); position:relative; top:-3px; } #footer { margin-left: auto; margin-right: auto; overflow: hidden; word-wrap: break-word; background: #FFFFFF; text-align: left; width: 700px; padding-bottom:5px; } #content { margin-left: auto; margin-right: auto; overflow: hidden; word-wrap: break-word; background: #FFFFFF; text-align: left; width: 700px; } #content p { font-family: 'HelveticaNeue', 'Helvetica Neue', 'arial', sans-serif; font-size: 12px; font-weight:normal; color: #A9A9A9; padding-bottom:2px; } #left { width:200px; float:left; padding-top:15px; padding-left:8px; padding-bottom:15px; } #right{ width:480px; float:right; padding:5px; padding-top:15px; padding-bottom:15px; } #rightleft { widht:250px; float:left; padding-bottom:15px; border-style:solid; border-top-width:2px; border-bottom-width:2px; border-left-width:2px; border-right-width:1px; } #rightright { float:right; padding-bottom:15px; border-style:solid; border-top-width:2px; border-bottom-width:2px; border-left-width:1px; border-right-width:2px; } #rightleftheader { padding-right:180px; border-style:solid; border-bottom-width:2px; border-right-width:2px; } #rightrightheader { padding-right:250px; border-style:solid; border-bottom-width:2px; } h2 { font-family: Verdana; font-size: 14px; font-weight:400; color: #005493; text-align: left; font-stretch: normal; font-style: normal; padding-bottom:5px; } #leftbox { width:180px; background: #94DAFF; font-family: 'HelveticaNeue', 'Helvetica Neue', 'arial', sans-serif; font-size: 12px; padding:5px; font-weight:normal; color: #FFFFFF; } #leftbox h3 { font-family: 'HelveticaNeue', 'Helvetica Neue', 'arial', sans-serif; font-size: 14px; padding:5px; font-weight:Bold; color: #FFFFFF; text-align: center; } #leftbox a { font-family: 'HelveticaNeue', 'Helvetica Neue', 'arial', sans-serif; font-size: 12px; padding:5px; font-weight:normal; color: #FFFFFF; text-decoration: none; font-weight:none; } #leftbox a:hover { text-decoration: Underline; } #pagetitle { font-family: Verdana; font-size: 18px; font-weight:400; color: #005493; text-align: left; font-stretch: normal; font-style: normal; padding-bottom:5px; } If anyone can help it would be great. Thanks, Blink359
-
so session_start(myusername); session_start(mypassword); Rather than session_register("myusername"); session_register("mypassword");
-
Hi there im trying to destroy a specific session i have been looking through many different ways on google but have yet to find one the reason i want to do this is because my website part of the website that is being made has to have a login to view everything and this login ontop to view restricted content, so far my logout has destroyed both sessions and i cant find an answer, all the nessecory scripts are listed below Login: <?php if(isset($_POST['code'])) { $host="***********"; // Host name $username="*************"; // Mysql username $password="************"; // Mysql password $db_name="******"; // Database name // Connect to server and select databse. mysql_connect($host, $username, $password); mysql_select_db($db_name); // username and password sent from form $myusername=$_POST['myusername']; $mypassword=$_POST['mypassword']; // To protect MySQL injection (more detail about MySQL injection) $myusername = stripslashes($myusername); $mypassword = stripslashes($mypassword); $myusername = mysql_real_escape_string($myusername); $mypassword = mysql_real_escape_string($mypassword); // encrypt password $encrypted_mypassword=md5($mypassword); $sql="SELECT * FROM members WHERE username='$myusername' and password='$encrypted_mypassword'"; $result=mysql_query($sql); // Mysql_num_row is counting table row $count=mysql_num_rows($result); // If result matched $myusername and $mypassword, table row must be 1 row if($count==1){ // Register $myusername, $mypassword and redirect to file "login_success.php" session_register("myusername"); session_register("mypassword"); header("location:jncomenu.php"); } else { echo "Wrong Username or Password"; } } ?> Check session: <? session_start(); if(!session_is_registered(myusername)){ header("location:JNCOlogin.php"); } ?> Logout: <? session_start(myusername); session_destroy(myusername); header("location:index.php"); ?> The first session is the same script bar [session_register("username"); session_register("password"); /php] Any help will be greatly appriciated. Thank, Blink359
-
Sorry, my host is playing up its not been uploaded properly but it works now, thanks, also while im on the forum i have a login to a restricted area of the website and you have to log in to view the whole thing but im not sure how to destroy 1 session so that they log out of the restricted and go back to the main site, i tried using <? session_start(myusername); session_destroy(myusername); header("location:index.php"); ?> to destroy the 2nd one but it also destroys the first one requiring users to log in again which is annoying, Any ideas? Blink359
-
Still Parse error: syntax error, unexpected T_STRING in /home/a9855336/public_html/261/cadetinfo.php on line 48
-
Hi there, just trying to make my while loop for echoing data look better but ive now got an error: Parse error: syntax error, unexpected T_STRING in /home/a9855336/public_html/261/cadetinfo.php on line 48 and im not sure what ive done wrong here is my code, line 48 is marked <?php $fldtextArea_name = str_replace("<br>", "\n", $fldtextArea_name); //connect to the databas mysql_connect("m*******","a********_root","n*********"); mysql_select_db("m***********"); //add the email to from @valiantflight.co.uk $from = $from."@valiantflight.co.uk"; //query database and pull email addresses $result = mysql_query("SELECT * FROM mail"); while ($row = mysql_fetch_array($result)) { ?> 48 <div id="rightleft"><?php echo('Name:'. $row['Name'] .'); ?></div><div id="rightright"><?php echo('Email:'. $row['Email'] .'<br>'); ?></div> <?php } ?> Any help would be very appriciated, Thanks, Blink359
-
How to say it (select ... from where .... and ...)
blink359 replied to egturnkey's topic in PHP Coding Help
If its just blank and not null i belive $result = mysql_query("SELECT * FROM info"); while ($row = mysql_fetch_array($result)) { if($row['name'] !='') { echo 'id:'. $row['id'] .' name:'. $row['name'] .'number:'. $row['number'] .'<br>'; } } would work, Just tested it with different values in my database and it worked -
When it errors now it does exactly what it's meant to but it resets the field anyway to stop that, otherwise people could get very annoyed
-
Ahh thank you i will go edit now
-
Hi im trying to mix php and html in a form however when i do this the whole page disapears and i dont know why the working form is: http://valiantflight.comlu.com/emailer/contact.php <html> <head> <title>Contact Us</title> </head> <body> <fieldset> <legend>Contact Us</legend> <form action="contact.php" method="post"> <input type="hidden" name="frmsubmit"> Your Email:*<br> <input type="text" name="email"><br> Subject:*<br> <select name="subject"> <option value=""></option> <option value="1">Recruitment</option> <option value="2">Absense</option> <option value="3">Enquiry</option> </select> <br> Message:*<br> <textarea name="message" cols="50" rows="5"></textarea> <br> <?php require_once('recaptchalib.php'); $publickey = "6LeB8LwSAAAAAKwvC3HWJNwWw9vYiSEkvFEvDduD"; // you got this from the signup page echo recaptcha_get_html($publickey); ?> <br> <input name"Submit" type="submit" value="Send Email"> </form> Required fields are marked with a *<br><br> <?php if(isset($_POST['frmsubmit'])){ $email = $_POST['email']; $subject = $_POST['subject']; $message = $_POST['message']; //checcking that all relevent information is entered and correct require_once('recaptchalib.php'); $privatekey = "6LeB8LwSAAAAAA_0IIEnAxL5uOau0TBm83Iog7Ey"; $resp = recaptcha_check_answer ($privatekey, $_SERVER["REMOTE_ADDR"], $_POST["recaptcha_challenge_field"], $_POST["recaptcha_response_field"]); if(!$message || !$email || !$subject) { $errmessage ="<font color='red'>The marked areas in the form have not been filled in correctly.</font>"; } if (!$resp->is_valid) { $errmessage ="<font color='red'>The text entered does not match the picture provided.</font>"; } //Sending the email if nothing is wrong if(!$errmessage) { header("location:send.php?subject=".$subject."&email=".$email."&message=".$message.""); }else{ echo $errmessage; } } ?> </fieldset> <br><br><br> </body> </html> and the one that doesnt work is: http://valiantflight.comlu.com/emailer/test/contact.php <html> <head> <title>Contact Us</title> </head> <body> <fieldset> <legend>Contact Us</legend> <form action="contact.php" method="post"> <?php if(isset($_POST['frmsubmit'])){ $email = $_POST['email']; $subject = $_POST['subject']; $message = $_POST['message']; //checcking that all relevent information is entered and correct ?> <input type="hidden" name="frmsubmit"> Your Email:*<br> <input type="text" name="email"> <?php if(!$email) { $errmessage ="<font color='red'>The marked areas in the form have not been filled in correctly.</font>"; echo("<font color='red'><br>Please enter your email.</font>"); } ?> <br> Subject:*<br> <select name="subject"> <option value=""></option> <option value="1">Recruitment</option> <option value="2">Absense</option> <option value="3">Enquiry</option> </select> <?php if(!$subject) { $errmessage ="<font color='red'>The marked areas in the form have not been filled in correctly.</font>"; echo("<font color='red'><br>Please select a subject.</font>"); } ?> <br> Message:*<br> <textarea name="message" cols="50" rows="5"></textarea> <?php if(!$message) { $errmessage ="<font color='red'>The marked areas in the form have not been filled in correctly.</font>"; echo("<font color='red'><br>Please enter a message to send.</font>"); } ?> <br> <?php require_once('recaptchalib.php'); $publickey = "6LeB8LwSAAAAAKwvC3HWJNwWw9vYiSEkvFEvDduD"; // you got this from the signup page echo recaptcha_get_html($publickey); require_once('recaptchalib.php'); $privatekey = "6LeB8LwSAAAAAA_0IIEnAxL5uOau0TBm83Iog7Ey"; $resp = recaptcha_check_answer ($privatekey, $_SERVER["REMOTE_ADDR"], $_POST["recaptcha_challenge_field"], $_POST["recaptcha_response_field"]); if (!$resp->is_valid) { $errmessage ="<font color='red'>Some parts of the form have not been entered correctly and have been marked above</font>"; echo("<font color='red'>The text you entered does not match the picture provided.</font>"); } ?> <br> <input name"Submit" type="submit" value="Send Email"> </form> Required fields are marked with a *<br><br> <?php //Sending the email if nothing is wrong if(!$errmessage) { header("location:send.php?subject=".$subject."&email=".$email."&message=".$message.""); }else{ echo $errmessage; } } ?> </fieldset> <br><br><br> </body> </html> If anyone can help it would be really great Thanks, Blink359
-
Im trying to use an if isset to stop my error messages displaying before they submit the form it worked on another part of my website but wont work for this, It just wond submit the form at all when i click submit here is the code: <html> <head> </head> <body> <form action="contact.php" method="post"> <fieldset> <legend>Contact Us</legend> Your Email:*<br> <input type="text" name="email"><br> Subject:*<br> <select name="subject"> <option value=""></option> <option value="1">Recruitment</option> <option value="2">Absense</option> <option value="3">Enquiry</option> </select> <br> Message:*<br> <textarea name="message" cols="50" rows="5"></textarea><br> <?php require_once('recaptchalib.php'); $publickey = "6LeB8LwSAAAAAKwvC3HWJNwWw9vYiSEkvFEvDduD"; // you got this from the signup page echo recaptcha_get_html($publickey); ?> <br> <input type="submit" value="Send Email"> </form> Required fields are marked with a *<br><br> <?php if(isset($_POST['Submit'])){ $email = $_POST['email']; $subject = $_POST['subject']; $message = $_POST['message']; $to = "[email protected]"; //checcking that all relevent information is entered and correct if(!$message || !$email) { $errmessage ="Please fill in all required data."; } require_once('recaptchalib.php'); $privatekey = "6LeB8LwSAAAAAA_0IIEnAxL5uOau0TBm83Iog7Ey"; $resp = recaptcha_check_answer ($privatekey, $_SERVER["REMOTE_ADDR"], $_POST["recaptcha_challenge_field"], $_POST["recaptcha_response_field"]); if (!$resp->is_valid) { $errmessage ="The text you wrote did not match the image."; } //Sending the email if nothing is wrong if(!$errmessage) { header("location:send.php?to=".$to."&subject=".$subject."&email=".$email."&message=".$message.""); }else{ echo $errmessage; } } ?> </fieldset> <br><br><br> </body> </html> And here is a link to the page: http://valiantflight.comlu.com/emailer/contact.php Any help will be greatly appriciated, Thanks, Blink359
-
ahh thanks, i've never done something like this ive only had to use != so far in ifs so i didnt know, it works now nad i have learnt 2 new things today
-
It's not the html its the php i moved half the script to another one and the drop down passed on the correct value the if statements are changing the value Script 1: <html> <head> </head> <body> <form action="contact.php" method="post"> <fieldset> <legend>Contact Us</legend> Your Email:*<br> <input type="text" name="email"><br> Subject:*<br> <select name="subject"> <option value="1">Recruitment</option> <option value="2">Absense</option> <option value="3">Enquiry</option> </select> <br> Message:*<br> <textarea name="message" cols="50" rows="5"></textarea><br> Please type the code shown in the image:<br><script type="text/javascript" src="http://webspamprotect.com/captcha/3096/"></script> <noscript>This form protected by <a href="http://webspamprotect.com" target="_blank" title="Web form spam protection">WebSpamProtect</a>. JavaScript must be enabled in your browser to view this image. </noscript> <input type="text" name="wsp_code"/><br> <input type="submit" value="Send Email"> </form> Required fields are marked with a *<br><br> <?php if(isset($_POST)) { $email = $_POST['email']; $subject = $_POST['subject']; $message = $_POST['message']; $to = "[email protected]"; //checcking that all relevent information is entered and correct include_once("wsp_captcha.php"); if (WSP_CheckImageCode() != "OK") { $errmessage="The image code you have entered is incorrect."; } //Sending the email if nothing is wrong if(!$errmessage) { header("location:send.php?to=".$to."&subject=".$subject."&email=".$email."&message=".$message.""); }else{ echo $errmessage; } } ?> </body> </html> Script 2: <?php $to = $HTTP_GET_VARS["to"]; $subject = $HTTP_GET_VARS["subject"]; $message = $HTTP_GET_VARS["message"]; $email = $HTTP_GET_VARS["email"]; if(!$email || !$message) { $errmessage ="Please fill in all required fields."; } if($subject="1") { $to="[email protected]"; } if($subject="2") { $to="[email protected]"; } if($subject="3") { $to="[email protected]"; } if($subject="1") { $subject="Recruitment"; } if($subject="2") { $subject="Absense"; } if($subject="3") { $subject="Enquiry"; } mail($to, $subject, $message ,"From: $email"); echo("Email Sent"); ?>
-
Hi there, I have created an email script and i want it to email a different email depending on the subject chosen by raido boxes however the if's aren't doing what they should, If i select say recruitement it choses the last option and has the wrong subject here is my code: <html> <head> </head> <body> <form action="contact.php" method="post"> <fieldset> <legend>Contact Us</legend> Your Email:*<br> <input type="text" name="email"><br> Subject:*<br> Recruitment Enquiry:<input type="radio" name="subject" value="Recruitment"> Absense Notification:<input type="radio" name="subject" value="Absense"> General Enquiry<input type="radio" name="subject" value="Enquiry"> <br> Message:*<br> <textarea name="message" cols="50" rows="5"></textarea><br> <input type="submit" value="Send Email"> </form> Required fields are marked with a *<br><br> <?php if(isset($_POST)) { $email = $_POST['email']; $subject = $_POST['subject']; $message = $_POST['message']; //checcking that all relevent information is entered and correct if(!$email || !$message) { $errmessage ="Please fill in all required fields."; } if($subject="Recruitment") { $to="email1"; } if($subject="Notification") { $to="email2k"; } if($subject="Enquiry") { $to="email3"; } //Sending the email if nothing is wrong if(!$errmessage) { header("location:send.php?to=".$to."&subject=".$subject."&email=".$email."&message=".$message.""); }else{ echo $errmessage; } } ?> </body> </html> If anyone can help it would be greatly appriciated Thanks, blink359
-
Hi there i was wondering how i would go about using html tags inside the php tags so i could put data from a database into a textarea / text input i had a go but had no such luck with this attempt: <?php echo "Title:<br>"; echo "<input type="text" name="title" value="$row['Title']">"; ?> the code above is to give you an idea of what i want to do, if you can point me to any guides or show me how it will be greatly appriciated Thanks, Blink359
-
Thanks very much using mysql_error(); i found my problem Thanks, Blink359
-
<?php $host="mysql12.000webhost.com"; // Host name $username="a9855336_root"; // Mysql username $password="n4th4n%"; // Mysql password $db_name="a9855336_mail"; // Database name // Connect to server and select databse. mysql_connect($host, $username, $password); mysql_select_db($db_name); $query = "SELECT title, content, FROM members WHERE id = '1'"; $result = mysql_query($query); $row = mysql_fetch_array($result); echo $row['title']; echo $row['content']; ?> Its now got the semi colon but Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/a9855336/public_html/test.php on line 14 Its this i was initially wanting to get fixed i obviously took the semi colon out by axedent before post
-
Hi, Im getting this error with my script that im using to try and echo content for my website: Parse error: syntax error, unexpected T_ECHO in /home/a9855336/public_html/test.php on line 16 my php code is <?php $host="mysql12.000webhost.com"; // Host name $username="a9855336_root"; // Mysql username $password="n4th4n%"; // Mysql password $db_name="a9855336_mail"; // Database name // Connect to server and select databse. mysql_connect($host, $username, $password); mysql_select_db($db_name); $query = "SELECT title, content, FROM members where ID = 1"; $result = mysql_query($query); $row = mysql_fetch_array($result) echo $row['title']; ?> html stuff <?php echo $row['content']; ?> If anyone can help me fix this problem or sugguest a dfiferent way to go about this it would be greatly appriciated. Thanks, Blink359
-
Dont worry, sorted, thank you ever so much for your help Blink359
-
ahh dont worry had a typo on the table name, but its not redirecting to the last page if($count==1){ // Register $myusername, $mypassword and redirect to file "login_success.php" session_register("myusername"); session_register("mypassword"); header("location:login_success.php");
-
Im entering the correct info and its coming back "bool(false)" :S
-
Thanks thats seem to fix a lot its now just Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/a9855336/public_html/checklogin.php on line 28 // Mysql_num_row is counting table row $count=mysql_num_rows($result); // If result matched $myusername and $mypassword, table row must be 1 row Thanks Blink359
-
Hi i followed a guid to create a login area to my site however i believe its a little outdated and therefore not working, i have done a little bit but being quite new i cannot find all the problems at the moment i have: Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/a9855336/public_html/checklogin.php on line 12 here is my script line 12 is marked <?php $host="*************"; // Host name $username="a9855**6_root"; // Mysql username $password="************"; // Mysql password $db_name="****3***36_mail; // Database name // Connect to server and select databse. mysql_connect($host, $username, $password) mysql_select_db($db_name); // username and password sent from form $myusername=$_POST['myusername']; // line 12 $mypassword=$_POST['mypassword']; // To protect MySQL injection (more detail about MySQL injection) $myusername = stripslashes($myusername); $mypassword = stripslashes($mypassword); $myusername = mysql_real_escape_string($myusername); $mypassword = mysql_real_escape_string($mypassword); // encrypt password $encrypted_mypassword=md5($mypassword); $sql="SELECT * FROM $tbl_name WHERE username='$myusername' and password='$encrypted_mypassword'"; $result=mysql_query($sql); // Mysql_num_row is counting table row $count=mysql_num_rows($result); // If result matched $myusername and $mypassword, table row must be 1 row if($count==1){ // Register $myusername, $mypassword and redirect to file "login_success.php" session_register("myusername"); session_register("mypassword"); header("location:login_success.php"); } else { echo "Wrong Username or Password"; } ?> if you help please tell me the error so i can learn to debug scripts myself in the future thanks blink359
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title></title> <meta name="keywords" content="" /> <meta name="description" content="" /> <link href="styles.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="main"> <!-- header begins --> <div id="header"> <div id="logo"> </div> <div id="buttons"> <ul> <li class="first"> <a href="#" title="">Home</a></li> <li><a href="#" title="">Calendar</a></li> <li><a href="#" title="">Gallery</a></li> <li><a href="#" title="">Events</a></li> <li><a href="#" title="">Flight Comp</a></li> <li><a href="#" title="">Login</a></li> <li><a href="#" title="">Contact Us</a></li> <li><a href="#" title="">261 Website</a></li> </ul> </div> </div> <!-- header ends --> <!-- content begins --> <div id="cont_top"></div> <div id="content"> <div id="left"> <h2>Contact Us</h2> <div class="text"> <form action="contact.php" method="post"> To:*<br> *****:<input type="radio" name="to" value="****" />******:<input type="radio" name="to" value="*****" />*****:<input type="radio" name="to" value="*****" />Webmaster:<input type="radio" name="to" value="webmaster" /><br> Your email:*<br> <input name="email" type="text"><br> Subject:*<br> <input name="subject" type="text"><br> Message:*<br> <textarea rows="5" cols="50" name="message"></textarea><br> <input type="submit" name="Submit" value="Send Email"> </form> <?php $to = $_POST['to']; $email = $_POST['email']; $subject = $_POST['subject']; $message = $_POST['message']; if(!$email || !$subject || !$to || !$message) { die('Please fill in all required fields'); } if($to = "*****") { $to=""; } if($to = "*******") { $to=""; } if($to = "******") { $to=""; } if($to = "*****") { $to=""; } if($to = "webmaster") { $to="*********"; } //Add their email at bottom of message $message = $message."Reply to: $email"; mail($to, $subject, $message ,"From: $email nReply-To: $email"); echo "Email Sent"; ?> <br> Click <a href="contact.html">here</a> to return to the previous page <br></div> <div> <h2>News!</h2> <div id="col_l"> <div class="text"> <span>News item 1</span> <br /> Text for news item 1<br /> </div> </div> <div id="col_r"> <div class="text"> <span>News item 2</span> <br /> Text for news item 2<br /> </div> </div> </div> </div> <div id="right"> <h1>Useful Links</h1> <ul> <li> Mailing List<br> </li> <li> Nco Area </li> </ul> <br /> </div> <div style="clear: both"><img src="images/spaser.gif" alt="" width="1" height="1" /></div> </div> <!-- content ends --> <div id="cont_bot"></div> <!-- footer begins --> <div id="footer"> Copyright 2010. Designed by <a href="http://www.metamorphozis.com/" title="Flash Templates">Flash Templates</a><br /> <a href="#">Privacy Policy</a> | <a href="#">Terms of Use</a> | <a href="http://validator.w3.org/check/referer" title="This page validates as XHTML 1.0 Transitional"><abbr title="eXtensible HyperText Markup Language">XHTML</abbr></a> | <a href="http://jigsaw.w3.org/css-validator/check/referer" title="This page validates as CSS"><abbr title="Cascading Style Sheets">CSS</abbr></a></div> <!-- footer ends --> </div> </body> </html>