Any suggestions on how I might go about doing this?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
linewire
Forum Newbie
Posts: 3
Joined: Sat Sep 26, 2009 12:16 am
Location: WA

Any suggestions on how I might go about doing this?

Post by linewire »

Basically I want to have siteA submit form data via POST to siteB.
SiteB then checks the database and says "username exists!" then redirects
you back to siteA with the error message.

I have it to where SiteA -> SiteB, processes the info, and shows the error, but how do I get
the error back to the original site? if I change the Location header then I just get
"the" error for modifying header output. Any suggestions? Thanks!!!!!!
User avatar
requinix
Spammer :|
Posts: 6617
Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA

Re: Any suggestions on how I might go about doing this?

Post by requinix »

linewire wrote:if I change the Location header then I just get
"the" error for modifying header output.
Then you should use "the" method of fixing that error: rearrange your code so the header() gets called before anything is output.


The fact that you're outputting something makes me suspicious that you don't quite understand how redirections work. Post code.
linewire
Forum Newbie
Posts: 3
Joined: Sat Sep 26, 2009 12:16 am
Location: WA

Re: Any suggestions on how I might go about doing this?

Post by linewire »

Then you should use "the" method of fixing that error: rearrange your code so the header() gets called before anything is output.


The fact that you're outputting something makes me suspicious that you don't quite understand how redirections work. Post code.
I thought I knew but maybe I don't. I placed the header() so it was called first also but then I couldn't send the $error variable along with it.
Post Reply