This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * This curl function might be useful when get_file_contents() cannot be used for any reasons. | |
| * E.g. when you need to pass user agent etc. | |
| * | |
| * Todo: return array with response code & the content | |
| */ | |
| function get_curl_output_by_url ( $_curl_url ) { | |
| $ch = curl_init(); | |
| $useragent="Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1"; |
NewerOlder