3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function Math(){ ?><script type="text/javascript" src="//code.jquery.com/jquery-1.11.3.min.js"></script><script type="text/javascript">Math.random();</script> <?php } ?> <?php $Url = "http://tinyz.us/dl25085"; $vars = "login_user=AmirMahmood&login_password=ammhd1374&captcha_code="; $cookie_file = file_get_contents("http://filmsdownload.tk/cookie.txt"); $ch = curl_init(); // Now set some options (most are optional) // Set URL to download curl_setopt($ch, CURLOPT_URL, $Url); // Set a referer curl_setopt($ch, CURLOPT_REFERER, "http://tinyz.us/"); // User agent curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/32.0.1700.107 Chrome/32.0.1700.107 Safari/537.36"); // Include header in result? (0 = yes, 1 = no) curl_setopt($ch, CURLOPT_HEADER, 0); // Should cURL return or print out the data? (true = return, false = print) curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); // curl_setopt($ch, CURLOPT_POST, 1); // curl_setopt($ch, CURLOPT_POSTFIELDS, $vars); curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie_file); curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_file); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); // Timeout in seconds curl_setopt($ch, CURLOPT_TIMEOUT, 10); // Download the given URL, and return output $output = curl_exec($ch); // Close the cURL resource, and free system resources curl_close($ch); echo $output; ?>
Output for 7.0.0 - 7.2.9
Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: System error in /in/qfOV2 on line 12 Warning: file_get_contents(http://filmsdownload.tk/cookie.txt): failed to open stream: php_network_getaddresses: getaddrinfo failed: System error in /in/qfOV2 on line 12 Fatal error: Uncaught Error: Call to undefined function curl_init() in /in/qfOV2:13 Stack trace: #0 {main} thrown in /in/qfOV2 on line 13
Process exited with code 255.
Output for hhvm-3.22.0
Warning: Failed to open http://filmsdownload.tk/cookie.txt (Could not resolve host: filmsdownload.tk) in /in/qfOV2 on line -1
Output for hhvm-3.15.4 - 3.21.3
Warning: Failed to open http://filmsdownload.tk/cookie.txt (Could not resolve host: filmsdownload.tk) in /in/qfOV2 on line 12
Output for 5.6.30
Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: System error in /in/qfOV2 on line 12 Warning: file_get_contents(http://filmsdownload.tk/cookie.txt): failed to open stream: php_network_getaddresses: getaddrinfo failed: System error in /in/qfOV2 on line 12 Fatal error: Call to undefined function curl_init() in /in/qfOV2 on line 13
Process exited with code 255.