Forum Moderators: coopster

Message Too Old, No Replies

moving the user to a new page

         

Babylon Jasmine

3:27 pm on May 14, 2007 (gmt 0)

10+ Year Member



OK, I was on here a little while ago looking for help on getting information into MySQL. I figured that out and my little PHP script works fine, except for one thing, after the data is submitted there is just a blank page. What can I do about this? I assumed there would be some fairly simple PHP function to redirect the user after they submitted their info, but if there is I certainly can't find it. Maybe I am going about it wrong and need to change the action on form submit from PHP_Self to something else? Or should I just put an entire page into the if statement after PHP submits the info? Any hints or clues would be greatly appreciated.

mcavic

3:39 pm on May 14, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



At the top of your form handler script:
ob_start();

Then when it's ready to redirect the user:
header("Location: http://whatever/");

[edited by: eelixduppy at 7:41 pm (utc) on May 14, 2007]
[edit reason] delinked [/edit]