I'm creating something similar to a proxy browser.
For this I need to get the source code from websites. I tried this in PHP with curl, file_get_contents and fopen. This is working very well for many websites.
But for some websites I'm asked to solve a Captcha or I'm getting a message like "failed to open stream: HTTP request failed! HTTP/1.1 403 Forbidden in - on line 12".
When opening this website in a browser, there are no problems, although I'm using the same user agent and IP address as in my PHP script. This means, for the website I want to access, there is some difference between my PHP script and my browser. But, what is it? How can I make my PHP script act like my browser for the website I want to get the source code from?
I need to get this work, no matter if you use curl, file_get_contents, fopen or anything else. I'll attach a file with my source code. I'll tell you a URL you can test it with via private chat.
Who can do that for me?
7 freelanceria on tarjonnut keskimäärin 29$ tähän työhön
I can handle the errors . Give me the list of sites you are facing the error and I will fix them for you using curl. Please share details over chat.
Hi, ⭐ I can complete this job successfully and quickly. I think you should send the header information in CURL. I am ready to start work immediately. Please contact me, Thanks