简体   繁体   中英

how to login to another site via PHP

I wanted to find out how to login to another site via PHP... I don't know the proper term for it, but basically, I want a user to be able to enter their login information for another website on mine, and interact with it through mine.Is there any tutorial? thanks

There are few ways to do the job (actually, you just need to send POST data to the other site).

You can use :

curl will do that PHP, cURL post to login to WordPress

but you will need that installed on the server which is sometimes not an option. There is however loads of scripts that can do the same thing as curl without the curl libs installed, eg: cakephp's HttpSocket class

as already stated, Curl will do that. But you can also check out this PHP Class that makes everything easier and gives you a lot of automation out of the Box Including Prefilling of CSRF Token, finding of all input fields, retrieving of details from the designated site. etc the class can be found Here. Crawl Engine

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM