Closed vinhtvu2 closed 4 years ago
Usage of file_get_contents() function: https://github.com/tchwork/utf8/search?q=file_get_contents&type=Code&utf8=%E2%9C%93
This function is used for reading files on the disk, not HTTP requests. I don't think cURL can even be used for that?
Ah, I see your example. Seems very unconventional. Surely people are more likely to have mb-string installed than curl?
It doesn't make sense to me to another extension dependency, when one of the aims of this package is to mitigate the absence of the mb-string extension?
Old and edgy.
We recently blocked set allow_url_fopen = 0 in php settings for security reason.
Is there anyway we can request for all the file_get_contents() functions to be converted to using curl? Either: http://snipplr.com/view/4084/curl-replacement-for-filegetcontents/ Or http://snipplr.com/view/51161/basic-curl-wrapper-function-for-php/
which include a default user-agent and option for setting user agent.
Thanks.