PHP sends curl to submit a login request, it receives code 302, and the automatic jump will return Code 411
All tests can be completed in postman, and the Location page after login is displayed correctly. However, when the postman output as php-curl: <?php include('php/simple_html_dom.php'); $username="username"; $password = 'password'; $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => 'https://somesite.com/', CURLOPT_RETURNTRANSFER => true, CURLOPT_TIMEOUT => 10, CURLOPT_ENCODING => '', CURLOPT_FOLLOWLOCATION => true, CURLOPT_MAXREDIRS => 10, CURLOPT_CUSTOMREQUEST => 'GET',