<?php
echo getYahooLinks("www.".$_REQUEST['domain']);
echo getYahooLinks($_REQUEST['domain']);
function getYahooLinks($sURL)
{
$url="https://siteexplorer.search.yahoo.com/advsearch?p=http%3A%2F%2F".urlencode($sURL)."&bwm=i&bwmo=d&bwmf=u";
$data=curl($sURL);
$spl=explode("</strong> of about <strong>",$data);
$spl2=explode("</strong>",$spl[1]);
$ret=trim($spl2[0]);
if(strlen($ret)==0) { return(0); } else { return($ret); }
}
function curl($sURL)
{
$useragent="Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1";
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_USERAGENT, $useragent);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER ,1);
curl_setopt($ch, CURLOPT_COOKIEJAR, "./cookie-jar.txt");
curl_setopt($ch, curlOPT_COOKIEFILE, "./cookie-jar.txt");
// curl_setopt($ch, CURLOPT_FOLLOWLOCATION ,1);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_AUTOREFERER, 0);
$data=curl_exec($ch);
curl_close($ch);
return $data;
}
?>
<?php
if(!isset($_REQUEST['domain']))
{
?>
<table border="0" width="100%" height="100%">
<tr><td>
<form method="GET">
<center>
<table>
<tr><td><b>Links - </b><br />input domains to find backLinks for</td><tr>
<tr><td><textarea name="domain" cols="40" rows="10"></textarea></td></tr>
<tr><td><input type="Submit" value="Lookup"></td></tr>
</form>
</center>
</td></tr>
</table>
<?
}
else
{
$urls=explode("\n",str_replace("www.","",str_replace("http://","", str_replace("\r","",trim($_REQUEST['domain'])))));
for($i=0; $i<sizeof($urls); $i++)
{
echo "$urls[$i] - ".getYahooLinks($urls[$i])."<br />";
echo "www.$urls[$i] - ".getYahooLinks("www.".$urls[$i])."<br />";
}
}
function getYahooLinks($sURL)
{
$url="https://siteexplorer.search.yahoo.com/advsearch?p=http%3A%2F%2F".urlencode($sURL)."&bwm=i&bwmo=d&bwmf=u";
$data=curl($sURL);
$spl=explode("</strong> of about <strong>",$data);
$spl2=explode("</strong>",$spl[1]);
$ret=trim($spl2[0]);
if(strlen($ret)==0) { return(0); } else { return($ret); }
}
function curl($sURL)
{
$useragent="Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1";
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_USERAGENT, $useragent);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER ,1);
curl_setopt($ch, CURLOPT_COOKIEJAR, "./cookie-jar.txt");
curl_setopt($ch, curlOPT_COOKIEFILE, "./cookie-jar.txt");
// curl_setopt($ch, CURLOPT_FOLLOWLOCATION ,1);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_AUTOREFERER, 0);
$data=curl_exec($ch);
curl_close($ch);
return $data;
}
?>
We use essential cookies to make this site work, and optional cookies to enhance your experience.