Jump to content

[SOLVED] Row updating from another table?


A2xA

Recommended Posts

I've tried this and I couldn't get it to work so I was seeing if I could just do this.  Cause the forum software I'm using is smf and the registration script is very complicated through different php files.  I'll try and mess with it some more though.

 

The code I was trying to use:

 

<?php
$name = $_POST['x'];
$user = $_POST['x'];
$pass = $_POST['x'];
$pass_c = $_POST['x'];
$email = $_POST['xl'];


// Insert user into the database
   $query = 'INSERT INTO users (userName, userUser, userPass, userEmail) VALUES ("' . $name . '", "' . $user . '", "' . md5($pass) . '", "' . $email . '")';
   mysql_query($query, $link);
?>

if the query don't work and u don't know why error check it

<?php
$name = $_POST['x'];
$user = $_POST['x'];
$pass = $_POST['x'];
$pass_c = $_POST['x'];
$email = $_POST['xl'];


// Insert user into the database
   $query = 'INSERT INTO users (userName, userUser, userPass, userEmail) VALUES ("' . $name . '", "' . $user . '", "' . md5($pass) . '", "' . $email . '")';
   mysql_query($query, $link) or die(mysql_error()."<br /><br />\n\n".$query);
?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.