I want to download a csv file from a url and save that on my server. But the URL requires a username/password.
And I also want to include a timeout, so that it will not try to download it longer than 30 seconds.
I currently tried this, but that is missing the username / password.
How can I achive this?
file_put_contents("file.csv", fopen("http://url.com/path/to/file.csv", 'r'));