SEOstats/Services/3rdparty/GTB_PageRank.php
// _ieHash - Checksum algorithm used in the IE version of the Google Toolbar.
Checksum algorithm used in the IE version of the Google Toolbar.
Checksum algorithm used in the IE version of the Google Toolbar .
public static function _ieHash ($a) {
    $NumHashString = sprintf('%u', self::hashmixIE($a));
    $NumHashLength = strlen($NumHashString);
    $CheckByte = 0;
    for ($i=($NumHashLength-1); $i>=0; $i--) {
        $Num = $NumHashString{$i};
        $CheckByte += (1===($i % 2)) ? (int)((($Num*2)/10)+(($Num*2)%10)) : $Num;
    }   $CheckByte %= 10;
    if ($CheckByte !== 0) {
        $CheckByte = 10-$CheckByte;
        if (($NumHashLength % 2) === 1) {
            if (($CheckByte % 2) === 1) {
                $CheckByte += 9; }
            $CheckByte >>= 1; }
    }
    return '7'.$CheckByte.$NumHashString;
  }
public static function _ieHash ( $ a ) { $ NumHashString = sprintf ( '%u' , self :: hashmixIE ( $ a ) ) ; $ NumHashLength = strlen ( $ NumHashString ) ; $ CheckByte = 0 ; for ( $ i = ( $ NumHashLength - 1 ) ; $ i >= 0 ; $ i -- ) { $ Num = $ NumHashString { $ i } ; $ CheckByte += ( 1 === ( $ i % 2 ) ) ? ( int ) ( ( ( $ Num * 2 ) / 10 ) + ( ( $ Num * 2 ) % 10 ) ) : $ Num ; } $ CheckByte %= 10 ; if ( $ CheckByte !== 0 ) { $ CheckByte = 10 - $ CheckByte ; if ( ( $ NumHashLength % 2 ) === 1 ) { if ( ( $ CheckByte % 2 ) === 1 ) { $ CheckByte += 9 ; } $ CheckByte >>= 1 ; } } return '7' . $ CheckByte . $ NumHashString ; }
_ieHash - Checksum algorithm used in the IE version of the Google Toolbar.
_ieHash - Checksum algorithm used in the IE version of the Google Toolbar .