There is example.com, which sometimes gives a redirect to example1.com, and sometimes to example2.com. It is necessary with the help of php "go" on example.com and find out the final link.
1 answer
See the cURL CURLOPT_FOLLOWLOCATION option and the CURLINFO_EFFECTIVE_URL parameter from curl_getinfo() .
|