August 1st, 2013, 04:15 AM
Automatic login to other site.
I have done a login page and set up all the database connection. its working and no problem with it. i want to login to another site.. lets think it to be gmail.com from my site. Is it possible to login into gmail account while i am entering the login details in my site and login and gmail account too without opening gmail.com
August 1st, 2013, 05:12 AM
How would you be able to login to your gmail account without first connecting to gmail.com?
Yes it's possible to login on your site and use something like curl for example to log you into gmail at the same time as the first login
August 1st, 2013, 05:51 AM
At the crudest level, you just replicate the login form, including the form's action and method.
However, some sites put measures in place to prevent this, as a precursor to avoiding CSRF.
gmail, for example does such a thing.
Taking a things on a bit you can build, or use an existing, http client in PHP to login (see snoopy, for example)....however I don't think you would then be able to transfer the session from the server to your local machine to take control.
A more elegant and robust solution is to see if the target site has an API you can use. In the case of gmail you can use the php imap functions to build yourself your own email client