Well, first, let me thank you for attaching the code instead of quoting it, and also for truncating the list of nations. When you say, "I put the whole page FYI," do you mean that all the scripts were combined into this document?
Second, if I may make a suggestion, take a look at
Tim Perdue's (---site author's!) excellent article on best practices/coding style. Clean code is easier for humans to understand, and therefore easier to a] teach with (by example, perhaps) and b] debug, which is what you're asking us to do.
I see one thing that may have bearing on this situation. In the HTML output by your echo() statements, you've assigned the values for the "stage" submit buttons like this:
echo "<input type=\"submit\" name=\"stage\" value=\"2\">";
But, then when you test the value, you use:
if ($stage==2) {
// whatever here
}
Now, one's a string, the other an integer. Likely PHP doesn't care much, but it's something to check. Some languages aren't so forgiving. And, it could be that some mistake like that is the problem....
Also, you missed escaping the quotes in your HTML, down where it says "this is
an image file and not a web page..."
I believe that it's "isset()", not "IsSet()" ... that might be important...
Where are the submits? Is this just a file that's included on some other
page?
Another thing, is register_globals ON or OFF on your server? :eek:
Finally, let me say 'thanks' for the debug joke, I was ROFL...hopefully you won't be banned from the forum 😃
Sorry if I'm not much help .... 🙁