I'm making a call to download an XML file and write it to a file using exec() and the curl command. I tried using curl_exec(), but it wasn't recognized by my PHP system.
Somehow, the cURL call now fails. It didn't before, but one day I visit my site and– WHAM. Bye bye XML parser.
Things that did work:
- Calling cURL from the command line with the same argument.
- exec("ls /");
Things that didn't work:
- which curl, then completing the path to the cURL in my exec function.
Googling the error that the curl throws when I output the errors from the exec function
ld.so.1: curl: fatal: /opt/csw/lib/libsunmath.so.1: unknown file type
Using shell_exec
- Using wget hung the script somehow. Just never finished.
- Self-flagellation