PHP Gods, Hear My Cry!


Sep 11, 2004
I've used PHP before, but nothing past the basics, however I do understand quite a few of the commands and concepts due to their relation to C+/C++. What I wish to do is create a simple program that I will run on my web server, which will query another server, take data and mirror it.

E.g. will mimic the data on

However, to access, you need to login via an html-based login. So when you try to connect to, you get redirected to where it asks you to input user and password data in an html form.

I have an account for, but I have no idea how I could get a PHP program to "send" the user/pass over when it connects to, bearing in mind it uses html-based form login, not a HTTP popup.

Also, how would I get it to take data from a table? I’ve worked with xml forms a bit, taking specific values, but I’ve never tried it with html.

Hope you can help, as I would really find a use for this program when I create it.

Thanks a load!


Feb 13, 2004
Ok, I've never tried this...but I think it can work.

You can send custom headers with php. It seems you would be able to "forge" a http POST response to the page that the login form specifies in the action field of the form.

So what you would be doing was skipping the login form and passing your username/password to the same page that the login form sends the information to.

Some links to check out: (read the comments especially)



Limp Gawd
Aug 24, 2004
It will also depend what, method of authenticating is. You have to figure out where the form sends the data, and simulate the send to it. If it uses POST variables, that would be the way to go. If it uses GET variables, you can just embed them in the URL you link to from your script. Ex: However, if they are using session variables or cookies, you would need to simulate those instead. Each are equally easy in PHP, just search the PHP manual for "session" or "cookies".