public function decrypt($y)
    {
        $t = ""; // 16-byte block
        $x = ""; // returned plain text;

        // put a 16-byte block into t
        $ysize = strlen($y);
        for ($i = 0; $i < $ysize; $i += 16) {
            for ($j = 0; $j < 16; $j++) {
                if (($i + $j) < $ysize) $t[$j] = $y[$i + $j]; else
                    $t[$j] = chr(0);
            }
            $x .= $this->decryptBlock($t);
        }

        return $x;
    }
public function decrypt($y)
    {
        $t = ""; // 16-byte block
        $x = ""; // returned plain text;

        // put a 16-byte block into t
        $ysize = strlen($y);
        for ($i = 0; $i < $ysize; $i += 16) {
            for ($j = 0; $j < 16; $j++) {
                if (($i + $j) < $ysize) $t[$j] = $y[$i + $j]; else
                    $t[$j] = chr(0);
            }
            $x .= $this->decryptBlock($t);
        }

        return $x;
    }
public function decrypt ( $ y ) { $ t = "" ; // 16-byte block $ x = "" ; // returned plain text; // put a 16-byte block into t $ ysize = strlen ( $ y ) ; for ( $ i = 0 ; $ i < $ ysize ; $ i += 16 ) { for ( $ j = 0 ; $ j < 16 ; $ j ++ ) { if ( ( $ i + $ j ) < $ ysize ) $ t [ $ j ] = $ y [ $ i + $ j ] ; else $ t [ $ j ] = chr ( 0 ) ; } $ x .= $ this -> decryptBlock ( $ t ) ; } return $ x ; }
Decrypts an aribtrary length String.

@param string $y ciphertext

@return  string plaintext
Whenever possible you should stream your ciphertext through the
decryptBlock() function directly, as the amount of time required
to decrypt is linear to the size of the ciphertext.
Decrypts an aribtrary length String .