Redirect a webpage

I have been trying to learn php, so please be patient with me.

I need help writing a redirect command. I have an index.php page. I need to put a code on it to check to see if my basic_info table is empty. If the table is empty, I want to redirect them to my setup.php.

If they are directed to setup.php and there is information in the table, then they need to be directed to the namechange.php page.

I want to make sure that they can only enter setup once with one user. This is going to be put on a USB drive so I can not make use of cookies to check this.

I had been using a wamp usb program, but was having to much trouble with table crashing so I switched to server2go. The original files that I used on the wamp program were header redirect files which worked perfectly. However server2go does not allow header files. I tried using the ob start command and it did not work.

I had used a meta redirect file, and it would only work to send them to the setup page, it would not send them to the name page

Does anyone have any ideas on how I can accomplish this?

Thanks
Snow Fox

what i dont understand is you are saying if the basic_info table is empty then redirect them to setup, and once they are redirected to there if it is not empty then send them somewhere else? if it is not empty should not be a problem because they would not have been sent to setup in the first place right?
did you add an if statement to check if it was empty before sending them?
could we see the scripts so we can get a good understanding of what you have going on, it would make life much easier!!!

Sponsor our Newsletter | Privacy Policy | Terms of Service