![]() |
cURL
Hey,
Was just wondering if this little bit of code could be converted to a cURL function instead of File_get_contents, a little but stumped about how to do that with this code, was wondering if anyone could do it? thanks. PHP Code:
|
This is how to use cURL to grab a file
PHP Code:
|
Would that work with the rest of the code though?
|
should do:
PHP Code:
|
Why do you want to use cURL anyway? I think Salathe pointed out a good way to get the HTTP headers in an earlier thread of yours.
|
I would recommend doing as above, but put the curl call into a function and name it like file_get_contents_curl or something, easier to understand then and more portable.
|
hmm, we'll, i tried it and it just constantly fails. not sure whats wrong.
|
Do you have the cURL extension installed? It needs to be installed to have cURL functionality in your website.
|
i have just about every extension installed and yes, that is one of them
|
I've modified it only slightly, but this works perfectly for me:
PHP Code:
|
Quote:
PHP Code:
PHP Code:
|
| All times are GMT. The time now is 06:07 AM. |
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0