For Programmers: Free Programming Magazines  


Home > Archive > PHP DB > January 2007 > Re: [PHP-DB] Error for registration mail.









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [PHP-DB] Error for registration mail.
Niel Archer

2007-01-07, 6:58 pm

Hi

You have two functions between the if and else, the syntax you've used
only allows one. Use braces.

if(mysql_query($sql)) {
mail ($email, "Thank you for registering!", $body, "From:
Malls@GurgaonShoppingMalls.com");
header("Location: thankYou.php");
} else {
die("Error! Could not insert values".mysql_error());
}


Niel
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com