Here's the code--
PHP Code:
<?php
$mydomain = "www.yourdomain.com"; // Set this to your domain
$list = file_get_contents("sites.txt");
$urls = explode ("\n", $list);
echo "<B>Checking back links to $mydomain....</B><P><FONT SIZE=-1>";
foreach ($urls as $url) {
if (strlen ($url)) {
echo $url . "<B><FONT COLOR=";
if (strpos (file_get_contents($url), $mydomain) != FALSE) {
echo "GREEN> Found";
} else {
echo "RED> Missing";
}
echo "</FONT></B><BR>";
}
}
echo "</FONT>";
?>
Reads a file (in the same directory) named sites.txt which is a list of URLs to check (separated by a carriage return).
----
found this simple reciprocal link checker but am having the same problem as Bill...
Warning: file_get_contents(http://www.frugalcarrental.com ): failed to open stream: No such file or directory in C:\Web\test\sitetest.php on line 18
RED> Missing
etc.etc.
I've got fopen set to on too. Checked securities & permissions for the file. Don't know where to go from here.
Thanks!!