This test script is designed to check whether the PHP fopen() function works on the server.

<?php
function get_content(){
$link = "http://google.com/";
$fd = fopen($link, "r");
$text="";
if ($fd == false) echo "Requested page not found 11";
else { while (!feof ($fd)) $text .= fgets($fd, 4096);
}
fclose ($fd);
echo $text;
}
get_content();
Copy this script into a file named test.php, upload it to the website folder, and open yoursite.com/test.php

The script will run successfully if two conditions are met:

  1. The server has open connections to external resources (port 80, http://google.com/)
  2. The PHP fopen() function is present and allowed