Skip to main content
Inspiring
February 3, 2007
Question

Update record problem PHP MYSQL

  • February 3, 2007
  • 3 replies
  • 310 views
hi all,
I have a problem with DW 8's update server behaviour. I'm not sure if its that or a MYSQL problem:
I have one page: upload2.php and there is an option for the user to change their password.

But when I enter the user details, and the new password, the database does not change at all.

Where am I going wrong?

This topic is closed to new replies. Start a new post to keep the conversation going.

3 replies

Inspiring
February 3, 2007
The_FedEx_Guy wrote:
> But when I enter the user details, and the new password, the database does not
> change at all.
>
> Where am I going wrong?

You have two forms which are mutually exclusive: form1 performs the
insert, form2 performs the update. Only one can be processed at a time.
For it to work, both actions need to be applied to the same form. You
would also need to run a check to see whether the user had entered a new
password. Otherwise you'll end up with a lot of people with a blank
password.

--
David Powers, Adobe Community Expert
Author, "Foundation PHP for Dreamweaver 8" (friends of ED)
Author, "PHP Solutions" (friends of ED)
http://foundationphp.com/
Inspiring
February 3, 2007
Hi,
I made the modifications and put the update form on a separate page. It works fine on my local machine.
But when I upload the file to my friends server i get weird errors:

Warning: Cannot modify header information - headers already sent by (output started at D:\companyname\wwwroot\sitefolder\update.php:6) in D:\companyname\wwwroot\sitefolder\update.php on line 52

I have removed the details for my friends company info
They have recently updated to PHP5 and MySQL 4++(current stable version)

Which header information is this? I have never come across this.