![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| ||||
| ||||
|
|
I am confused about what goes on with method POST. Here is an overview of a my code, sketching it out: ?php if (isset($_POST['Submit']) && $_POST['Submit']=="Submit") { ---Do a bunch of stuff--- if (isset($_SESSION['Error'])) unset($_SESSION['Error']); if (strcmp($A, "any") { |
|
// Verify that a Zip code is numeric and is five digits If (!is_numeric($_POST($zip)) strlen($_POST($zip)) != 5) then { |
|
$_SESSION['Error'] = "an error description"; header("Location: thisSite.php ; |
header("Location: anotherSite.php ; |
#3
| |||
| |||
|
#4
| |||
| |||
|
#5
| |||
| |||
|
|
I don't understand it, but I solved my immediate problem. If I put a line exit(); after the header("Location: thisSite.php"); line, then it works as I want. Someone please explain this to me. |
#6
| |||
| |||
|
|
Michael Fesser wrote: Where does $A come from? There's no value assigned to it in the code above. Additionally there's a ')' missing. Me: A is a control that is a list box that has distances. It the value is "any". an additional control appears that has the name "ziip". |
|
Michael: The Location-header requires an absolute URL. Me: Not true. I have been using relative URLs everywhere in my code and they work perfectly. |
![]() |
| Thread Tools | |
| Display Modes | |
| |