Answer the question
In order to leave comments, you need to log in
How to send fl.ru post request to php?
Hello. I want to parse fl.ru.
But I can't pass the parameters I need to sort the tasks.
Now it shows me 403 Forbidden
$url = "https://www.fl.ru/projects/";
$post_data = array (
"pf_keywords" => "php" // где php это слово для поиска
);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// указываем, что у нас POST запрос
curl_setopt($ch, CURLOPT_POST, 1);
// добавляем переменные
curl_setopt($ch, CURLOPT_POSTFIELDS, $post_data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question