S
S
Space2015-11-01 13:46:17
PHP
Space, 2015-11-01 13:46:17

How to click on cURL?

Let's take Instagram for example. There is a subscribe button.

<button class='..." data-reactid=".0.1.0.0:0.1.0.2.0">

How can I click on it using curl, I saw examples for Input:
curl_setopt($ch, CURLOPT_POSTFIELDS, "Submit=Go%21");

But how can I be here?
Moreover, in the page structure there are links of the form:
https://instagram.com/USER/?action=unfollow&hl=ru
, but if you insert them into a line and go, the action will not work.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey, 2015-11-01
Protko @Fesor

No way, CURL doesn't click, it sends an HTTP request. What you wrote there (submit=go...) is part of the HTTP request body.
Instagram has an HTTP API, and work with it.

A
Alexander Litvinenko, 2015-11-01
@edli007

You can only click on the screen, the curl does not click, it "follows the links".
The click launches some kind of script, which in turn sends something to the server, you need to figure out what exactly and send the same curl.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question