Can't get header(Location: ) to redirect.
Posted: Fri Dec 23, 2011 2:07 am
I'm not sure if this is a config problem or a code problem. I get no errors but the php line of code is not redirecting. As always, thanks in advance for any help.
Clark
Code: Select all
<?php
$objConnect = mysql_connect('localhost','user') or die(mysql_error());
$objDB = mysql_select_db("test");
for($i=0;$i<count($_POST["chkDel"]);$i++)
{
if($_POST["chkDel"][$i] != "")
{
$strSQL = "DELETE FROM customer WHERE CustomerID = '".$_POST["chkDel"][$i]."' ";
$objQuery = mysql_query($strSQL);
}
}
header("Location: http://localhost:8888/test/php_mysql_checkbox/php_mysql_checkbox1.php");
mysql_close($objConnect);
?>