[Solved] How to use php_CURL to acess a website [closed]

function get_web_page( $url ) { $options = array( CURLOPT_RETURNTRANSFER => true, CURLOPT_HEADER => false, CURLOPT_FOLLOWLOCATION => true, ); $ch = curl_init( $url ); curl_setopt_array( $ch, $options ); $content = curl_exec( $ch ); curl_close( $ch ); return $content; } echo get_web_page(“http://www.emirates.com/account/english/miles-calculator/miles-calculator.aspx?org=BOM&dest=JFK&trvc=0&h=7b1dc440b5eecbda143bd8e7b9ef53a27e364b”); 1 solved How to use php_CURL to acess a website [closed]

[Solved] libcurl – unable to download a file

Your code curl_easy_setopt(handle,CURLOPT_WRITEFUNCTION,&AZLyricsDownloader::write_data_to_var); and the following quote from the documentation from libcurl There’s basically only one thing to keep in mind when using C++ instead of C when interfacing libcurl: The callbacks CANNOT be non-static class member functions Example C++ code: class AClass { static size_t write_data(void *ptr, size_t size, size_t nmemb, void* ourpointer) { … Read more