From an external site, I need to present a form that POSTS data to secure.domain.com/index.php. Inside of index.php, I fill some hidden fields which in turn need to be posted to secure.domain.com/foo/index.php. I also set some session variables.
The reason for this is a temporary redirect while I finish building a user portal which will live at secure.domain.com/. In a couple of weeks, I will just need to post data to secure.domain.com/index.php
For now, however, I need to try and automatically log people in to what lies in secure.domain.com/foo/. I can't just change the target for the forms on various sites.
How might I accomplish this with PHP? Right now, I'm just presenting a "Click here to complete login" submit button on secure.domain.com/index.php , I'm hoping to get rid of that button.
Plan B is to put a captcha above the button and tell management that the quirk is by design for human verification purposes, since there was no room for one on the external site forms. I'd rather not do that.
Edit:
Thanks for all of the answers. It seems like there is no way to do this only using PHP. Internal users will be using thin clients with a very strict pre configured noscript plug-in, they can just deal with the button for a couple of weeks.