|
Posted by Rik on 10/02/51 11:55
ZafT wrote:
> Hi all - thanks in advance for any help.
>
> I am trying to write a simple update script. In fact, I am re-using
> code that I've used before (successfully) but I can't figure out why
> it is not working. The script completes without any errors, but does
> not actually update the database.
>
> Also, the "check for same name" query works fine, and will return the
> proper error if a duplicate is found.
> <?PHP
> require('header.php');
> require('config.php');
>
> mysql_connect($dbserver,$username,$password)
> or die( "Unable to connect");
> @mysql_select_db($database)
> or die( "Unable to select database");
>
> $id=$_POST['id'];
> $name=$_POST['name'];
> $description=$_POST['description'];
> $show=$_POST['show'];
$id = mysql_real_escape_string($_POST['id']);//etc...
If that doesn't work: echo the built query, and any mysql_error();
Grtz,
--
Rik Wasmus
[Back to original message]
|