Page 1 of 1

PAGE NOT LOADING!?

Posted: Wed Dec 03, 2008 8:09 am
by cyandi_man
I have a password change page that uses a php file that updates password on an mySQL database.
however when submit is hit i see the current page go blank and it does not redirect to the "password success" page. The password HAS indeed been updated - however there seems to be an issue with my header function that sends the user to the notification page. I have other sections in this website that use the EXACT same coding and it works without flaw!....eg. other member password update pages.

I am using IE - what on earth is going on??

Code: Select all

<?
$user="Proadmin";
  $host="localhost";
  $password="mypassword";
  $database = "mydatabase";
  $connection = mysql_connect($host,$user,$password)
       or die ("couldn't connect to server");
  $db = mysql_select_db($database,$connection)
       or die ("Couldn't select database");
  $db = mysql_select_db($database,$connection)
       or die ("Couldn't select database");
$clientN= $_POST['clnt'];
$user = $_POST['puser2'];
$password = $_POST['ppassword2'];
$query = "UPDATE vendors SET pass = '$password', user = '$user' WHERE vendor_number='$clientN'";
if(mysql_query($query)){
header("Location: http://provicanhealth.com/vendor_pass_successEX.php");
exit;
}
else{
header("Location: http://provicanhealth.com/vendor_passchange_errorEX.php");
exit;
}
?>

Re: PAGE NOT LOADING!?

Posted: Wed Dec 03, 2008 9:25 am
by jaoudestudios
Make sure no headers are being sent before your header redirect, even white space.

Re: PAGE NOT LOADING!?

Posted: Wed Dec 03, 2008 9:36 pm
by cyandi_man
jaoudestudios wrote:Make sure no headers are being sent before your header redirect, even white space.
did that ..the code above doesnt even have any spaces...
i even took out the "or die" lines just incase for some stupid reason they were causing the issue ...still no change in page behavior.

Re: PAGE NOT LOADING!?

Posted: Wed Dec 03, 2008 11:51 pm
by khalidmehmoodawan
Try using
error_reporting(E_ALL);
ini_set("display_errors", 1);

at the start of both pages.