View Single Post
  #17 (permalink)  
Old 12-05-2005, 12:00 PM
jazzmatazz2005 jazzmatazz2005 is offline
WebProWorld Member
 

Join Date: Aug 2003
Location: Jersey City, NJ
Posts: 71
jazzmatazz2005 RepRank 0
Default Ok

TrafficProducer....I understand what your talking about but tha data base is only 0.03 MB in size.

Here's a peice of my code where should i put a echo so i can debug?

Code:
<?
 if (isset($_POST['Add']))
  {
   require_once("conn.php");

   $cUsername = $_POST['username'];
   $cPassword = $_POST['password'];
   $cFullname = $_POST['fullname'];
   $cEmail = $_POST['email'];

   //Check for existing user
   $sq = "SELECT * FROM users WHERE username = '$cUsername'";
   $sr = mysql_query($sq) or die(mysql_error());
   if (mysql_fetch_array($sr)) die("Sorry. That user name already exists. Use your browsers back button and select a different username.");

   //Add if not exist
   $aq = "INSERT INTO users (username, password, fullname, email)
          VALUES ('$cUsername', '$cPassword', '$cFullname', '$cEmail')";
   $ar = mysql_query($aq);

   //Preare personal message record for this user
   $suq = "SELECT * FROM users WHERE username = '$cUsername'";
   $sur = mysql_query($suq) or die(mysql_error());
   $sua = mysql_fetch_array($sur);

   header("location:welcome.php");
  }

  require_once("templates/toptempl.php");
  require_once("templates/registertempl.php");
  require_once("templates/bottomtempl.php");
?>
__________________
It's better to do business with me than against me!
Reply With Quote