Вход Регистрация
Файл: servises/raiting/index.php
Строк: 231
<?
require'../../shaxty.php';
$align='left';
check_login();
$title='Конструктор грабберов';
include_once (
H.'shaxty/head.php');
echo 
'<br />';

?>
Проверка индекса цитирования сайта</br>
            <form action="?" method="post">
              Введите URL без http:// и www: </br>
              <input name='url' value='' size="20">
              <input type="submit" value="Проверить">
            </form>
            <hr>
            <?
$website 
check($_REQUEST['url']);
if( 
$website ){
    if( !
strstr($website,"http://") && !strstr($website,"https://") ){
        
$website "http://".$website;
    }
    
$linkedpages linkcheck($website,'google');
    
$indexedpages GoogleLinks($website);

    
$pr GooglePageRank($website);
    
$indexed $indexedpages[google][0];
    
$links $linkedpages[google][0];

    
$data = array();
    
$target trim(eregi_replace('http://'''$website));
    
// checking Google
    
$source 'http://www.google.com/search?hl=en&lr=&ie=UTF-8&q='.$target;
    
$data['Google'] = array(fetch($source'of about'9'linking''did not match any documents'), $source);
    
// checking MSN Search
    
$source 'http://search.msn.com/results.aspx?FORM=MSNH&srch_type=0&q=link%3A'.$target;
    
$data['MSN Search'] = array(fetch($source'web results1-'18'containing'"couldn't find any sites containing"), $source);
    
// checking Yahoo!
    
$source 'http://search.yahoo.com/search?p=linkdomain%3A'.$target.'&sm=Yahoo%21+Search&fr=FP-tab-web-t&toggle=1';
    
$data['Yahoo!'] = array(fetch($source'of about'9'for'"we didn't find any web pages"), $source);
    
// checking AlltheWeb
    
$source 'http://www.alltheweb.com/search?cat=web&cs=utf8&q='.$target.'&rys=0&_sb_lang=pref';
    
$data['AlltheWeb'] = array(fetch($source'audio1 -'14'results'"no web pagesfound that match your query"), $source);
    
// checking AltaVista
    
$source 'http://www.altavista.com/web/results?itag=wrx&q='.$target.'&kgs=1&kls=0';
    
$data['AltaVista'] = array(fetch($source'altavista found'15'results'"we found 0 results"), $source);

?>
         <table style="width: 100%;" cellspacing="0" cellpadding="0">
                Сайт:
                <td><a href="<?=$website?>">
                  <?=$website?>
                  </a></br><br/>
                Статус сайта:

                  <?=$pr?>
                  / 10</br><br/>

                Проиндексировано страниц:
                <a href="<?=$indexedpages[google][1]?>">
                  <?=$indexed?></br><br/>
                  </a>
                Обратных ссылок:
                <a href="<?=$linkedpages[google][1]?>">
                  <?=$links?>
                  </a></br><br/>

            <hr>
            Популярные ссылки на поисковиках:</br><br/>

              <?
        
foreach($data as $engine => $result) {
        
?>
              <a href='<? echo $result[1]; ?>' target='_blank'><? echo $engine?></a>
              <?
        $total 
+= preg_replace("[[:punct:]]"''$result[0]);
        }
        
?></br>
             <br/> Всего:
                <? echo $total?></br></br>
<br/><img src="http://www.yandex.ru/cycounter?<?php echo $website;?>" width=88 height=31 alt="Яндекс цитирования" border=0></br><br/>

Яндекс цитирования можете паставить на своем сайте..Разместите это изображение:</br>
<input value= http://www.yandex.ru/cycounter?<?php echo $website;?> ><br/> <br/>
</table>

          <?
}

function 
fetch($source$start$smlen$stop$fail) {
    
$data = @implode('', @file($source));
    
$data strip_tags($data);
    
$data strtolower($data);
    
$data str_replace("n"''$data);
    
$data str_replace("r"''$data);

    if(
substr_count($data$fail)) {
        return 
0;
    } else {
        
$data substr($datastrpos($data$start)+$smlen);
        
$data substr($data0strpos($data$stop));
        return 
trim($data);
    }
}

function 
linkcheck($url$engine) {
    global 
$time$total;
    
$arr parse_url($url);
    
$url $arr['host'];
    
$path "http://www.google.com/search?hl=en&lr=&ie=UTF-8&q=link%3A".$url;
    if(!
file_exists($path)) {
        
$data strtolower(strip_tags(implode(""file($path))));
        
$data substr($datastrpos($data"of about")+9strlen($data));
        
$data substr($data0strpos($data" "));
        if(
eregi("[[:alpha:]]"$data)) {
            
$results[$engine] = array('0'$path);
        } else {
            
$results[$engine] = array($data$path);
            
$total+=str_replace(','''$data);
        }
    } else {
        
$results[$engine] = array('n/a'$path);
    }
    return 
$results;
}
function 
GoogleLinks($url){
    
$arr parse_url($url);
    
$url $arr['host'];
    
$engine 'google';
    
$path 'http://www.google.com/search?q=inurl:'.$url.'&hl=en&lr=&ie=UTF-8&filter=0';
    if(!
file_exists($path)) {
        
$data str_replace('&nbsp;'' 'strtolower(strip_tags(@implode('', @file($path)))));
        if(!
strpos($data'did not match any documents')) {
            
$data substr($datastrpos($data'web results')+12strlen($data));
            
$data trim(substr($data0strpos($data'for'))); //echo $data; // TEST
            
$data explode(' '$data);
            
$data $data[(count($data)-1)];
            
$results[$engine] = array($data$path);
            
$total+=str_replace(','''$data);
        } else {
            
$results[$engine] = array('0'$path);
        }
    } else {
        
$results[$engine] = array('n/a'$path);
    }
    return 
$results;
}

function 
GooglePageRank($url){
    
$arr parse_url($url);
    
$url $arr['host'];
    
$url="info:".$url$ch=GoogleCSum($url,0xE6359A60);
    
$host="toolbarqueries.google.com"$hostip=gethostbyname($host);
    
$query ="GET /search?client=navclient-auto&ch=6".$ch."&ie=UTF-8&oe=UTF-8&features=Rank&q=".rawurlencode($url)." HTTP/1.0rn";
    
$query.="Host: $hostrn"$rank=-1;
    
$query.="User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)rn";
    
$query.="Connection: Closernrn";
    
$fp=fsockopen($hostip,80,$errno,$errstr,30);
    if (
$fp)
    { 
fputs($fp,$query); $data=""; while (!feof($fp)) $data.=fgets($fp,4096); fclose($fp);
    
$data=explode("n",$data);
    foreach (
$data as $line)
    if (!
is_bool(strpos($line,"Rank_1")))
    { 
$rank=explode(":",trim($line)); $rank=$rank[2]; break; } }
    return 
$rank;
}

function 
GoogleCSum($s,$key){
    
$v4=$len=strlen($s); $esi=$key$ebx=$edi=0x9E3779B9$p=0;
    if (
$len>=12)
    for(
$i=0;$i<floor($len/12);$i++)
    { 
$edi=unsign($edi+ord($s[$p+4])+(ord($s[$p+5]) << 8)+(ord($s[$p+6]) << 16)+(ord($s[$p+7]) << 24));
    
$esi=unsign($esi+ord($s[$p+8])+(ord($s[$p+9]) << 8)+(ord($s[$p+10]) << 16)+(ord($s[$p+11]) << 24));
    
$edx=unsign(($ebx+ord($s[$p+0])+(ord($s[$p+1]) << 8)+(ord($s[$p+2]) << 16)+(ord($s[$p+3]) << 24)-$edi-$esi)^shr($esi,13));
    
$edi=unsign(($edi-$esi-$edx)^($edx << 8));
    
$esi=unsign(($esi-$edx-$edi)^shr($edi,13));
    
$edx=unsign(($edx-$edi-$esi)^shr($esi,12));
    
$edi=unsign(($edi-$esi-$edx)^($edx << 16));
    
$esi=unsign(($esi-$edx-$edi)^shr($edi,5));
    
$edx=unsign(($edx-$edi-$esi)^shr($esi,3)); $ebx=$edx;
    
$edi=unsign(($edi-$esi-$ebx)^($ebx << 10));
    
$esi=unsign(($esi-$ebx-$edi)^shr($edi,15));
    
$v4-=12$p+=12; }
    
$esi=unsign($esi+$len);
    if (
$v4>=11$esi=unsign($esi+(ord($s[$p+10]) << 24));
    if (
$v4>=10$esi=unsign($esi+(ord($s[$p+9]) << 16));
    if (
$v4>=9$esi=unsign($esi+(ord($s[$p+8]) << 8));
    if (
$v4>=8$edi=unsign($edi+ord($s[$p+4])+(ord($s[$p+5]) << 8)+(ord($s[$p+6]) << 16)+(ord($s[$p+7]) << 24));
    else
    { if (
$v4>=7$edi=unsign($edi+(ord($s[$p+6]) << 16));
    if (
$v4>=6$edi=unsign($edi+(ord($s[$p+5]) << 8));
    if (
$v4>=5$edi=unsign($edi+ord($s[$p+4])); }
    if (
$v4>=4$ebx=unsign($ebx+ord($s[$p+0])+(ord($s[$p+1]) << 8)+(ord($s[$p+2]) << 16)+(ord($s[$p+3]) << 24));
    else
    { if (
$v4>=3$ebx=unsign($ebx+(ord($s[$p+2]) << 16));
    if (
$v4>=2$ebx=unsign($ebx+(ord($s[$p+1]) << 8));
    if (
$v4>=1$ebx=unsign($ebx+ord($s[$p+0])); }
    
$ebx=unsign(($ebx-$edi-$esi)^shr($esi,13));
    
$edi=unsign(($edi-$esi-$ebx)^($ebx << 8));
    
$esi=unsign(($esi-$ebx-$edi)^shr($edi,13));
    
$ebx=unsign(($ebx-$edi-$esi)^shr($esi,12));
    
$edi=unsign(($edi-$esi-$ebx)^($ebx << 16));
    
$esi=unsign(($esi-$ebx-$edi)^shr($edi,5));
    
$ebx=unsign(($ebx-$edi-$esi)^shr($esi,3));
    
$edi=unsign(($edi-$esi-$ebx)^($ebx << 10));
    
$esi=unsign(($esi-$ebx-$edi)^shr($edi,15)); return $esi;
}
function 
shr($x,$y) {
    
$x=unsign($x);
    for(
$i=0;$i<$y;$i++) $x=floor($x/2); return $x;
}
function 
unsign($l) {
    
$l=intval($l);
    if (
$l>=0){
        return 
$l;
    }else{
        return 
4294967296+$l;
    }
}

echo 
'<br />';
echo 
$div1.'<a href="/servises/">Сервисы</a>'.$div9;
include_once (
H.'shaxty/foot.php');
?>
Онлайн: 2
Реклама