PageRenderTime 5942ms queryFilters 40ms Sphinxql 75ms app.CodeModel.GetByIds 837ms findMatchingLines 53ms GetByIds 890ms meta 0ms repositoryFilters 10ms languageFilters 1ms sourceFilters 6ms

27,527 results for 'php chr repo:kohntark/PHPModbusTCP' (5942 ms)

Source

Language

Repository

getid3.lib.php git://github.com/wordpress/wordpress.git | PHP | 1,786 lines
112			if (!$hasINT64 && !defined('PHP_INT_MIN')) {
113				define('PHP_INT_MIN', ~PHP_INT_MAX);
114			}
116		// if integers are 64-bit - no other check required
117		if ($hasINT64 || (($num <= PHP_INT_MAX) && ($num >= PHP_INT_MIN))) { // phpcs:ignore PHPCompatibility.Constants.NewConstants.php_int_minFound
118			return true;
506		// written by kcØhireability*com
507		// taken from http://www.php.net/manual/en/function.array-merge-recursive.php
508		if (!is_array($array1) || !is_array($array2)) {
1722		if (GETID3_OS_ISWINDOWS) {
1723			if (class_exists('COM')) { // From PHP 5.3.15 and 5.4.5, COM and DOTNET is no longer built into the php core.you have to add COM support in php.ini:
1724				$filesystem = new COM('Scripting.FileSystemObject');
1773	/**
1774	 * Workaround for Bug #37268 (https://bugs.php.net/bug.php?id=37268)
1775	 *
Hash.php https://bitbucket.org/openemr/openemr.git | PHP | 825 lines
1<?php
2
3/**
4 * Pure-PHP implementations of keyed-hash message authentication codes (HMACs) and various cryptographic hashing functions.
5 *
12 *
13 * PHP version 5
14 *
19 * <code>
20 * <?php
21 *    include 'vendor/autoload.php';
22 *
23 *    $hash = new \phpseclib\Crypt\Hash('sha1');
24 *
32 * @package   Hash
33 * @author    Jim Wigginton <terrafrost@php.net>
34 * @copyright 2007 Jim Wigginton
BigInteger.php https://bitbucket.org/openemr/openemr.git | PHP | 3,755 lines
570                    $temp = bcmod($current, '16777216');
571                    $value = chr($temp >> 16) . chr($temp >> 8) . chr($temp) . $value;
572                    $current = bcdiv($current, '16777216', 0);
755     * Although you can call BigInteger::__toString() directly in PHP5, you cannot call BigInteger::__clone() directly
756     * in PHP5.  You can in PHP4 since it's not a magic method, but in PHP5, you have to call it by using the PHP5
757     * only syntax of $y = clone $x.  As such, if you're trying to write an application that works on both PHP4 and
2919        // generate as many leading 1's as we need to.
2920        $leading_ones = chr((1 << ($new_bits & 0x7)) - 1) . str_repeat(chr(0xFF), $new_bits >> 3);
2921        $this->_base256_lshift($leading_ones, $current_bits);
3029            $precision = 8 * strlen($bits) - 8 + $i;
3030            $mask = chr((1 << ($precision & 0x7)) - 1) . str_repeat(chr(0xFF), $precision >> 3);
3031        }
3224
3225        // gmp_nextprime() requires PHP 5 >= 5.2.0 per <http://php.net/gmp-nextprime>.
3226        if (MATH_BIGINTEGER_MODE == self::MODE_GMP && extension_loaded('gmp')) {
Services_JSON.php https://bitbucket.org/kgrashad/thawrapedia | PHP | 882 lines
55* @license http://www.opensource.org/licenses/bsd-license.php
56* @see http://pear.php.net/pepr/pepr-proposal-show.php?id=198
57*/
572					$utf8 = '';
573					$strlen_chrs = strlen($chrs);
574
766								 (($chrs{$c - 1} != '\\') ||
767								 ($chrs{$c - 1} == '\\' && $chrs{$c - 2} == '\\'))) {
768							// found a quote, we're in a string, and it's not escaped
806							for ($i = $top['where']; $i <= $c; ++$i)
807								$chrs = substr_replace($chrs, ' ', $i, 1);
808
832		if ( self::pearInstalled() ) {
833			//avoid some strict warnings on PEAR isError check (looks like http://pear.php.net/bugs/bug.php?id=9950 has been around for some time)
834			return @PEAR::isError($data, $code);
Hash.php https://bitbucket.org/norvin/mingen_dts | PHP | 816 lines
1<?php
2/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
4/**
5 * Pure-PHP implementations of keyed-hash message authentication codes (HMACs) and various cryptographic hashing functions.
6 *
13 *
14 * PHP versions 4 and 5
15 *
20 * <code>
21 * <?php
22 *    include('Crypt/Hash.php');
48 * @package    Crypt_Hash
49 * @author     Jim Wigginton <terrafrost@php.net>
50 * @copyright  MMVII Jim Wigginton
51 * @license    http://www.gnu.org/licenses/lgpl.txt
52 * @version    $Id: Hash.php,v 1.6 2009/11/23 23:37:07 terrafrost Exp $
53 * @link       http://phpseclib.sourceforge.net
getid3.lib.php https://bitbucket.org/norvin/mingen_dts | PHP | 1,309 lines
1<?php
2/////////////////////////////////////////////////////////////////
297			$quotient = ($number / ($maskbyte + 1));
298			$intstring = chr(ceil(($quotient - floor($quotient)) * $maskbyte)).$intstring;
299			$number = floor($quotient);
339		for ($i = 0; $i < strlen($binstringreversed); $i += 8) {
340			$string = chr(getid3_lib::Bin2Dec(strrev(substr($binstringreversed, $i, 8)))).$string;
341		}
349			if ($synchsafe) {
350				$intstring = $intstring.chr($number & 127);
351				$number >>= 7;
352			} else {
353				$intstring = $intstring.chr($number & 255);
354				$number >>= 8;
362		// written by kcŘhireability*com
363		// taken from http://www.php.net/manual/en/function.array-merge-recursive.php
364		if (!is_array($array1) || !is_array($array2)) {
String.php https://bitbucket.org/rlm3/rlm3_staging | PHP | 777 lines
33 * @package    PHPExcel_Shared
34 * @copyright  Copyright (c) 2006 - 2014 PHPExcel (http://www.codeplex.com/PHPExcel)
35 */
516	 * Assumes Big-Endian byte order if no BOM is available.
517	 * This function was taken from http://php.net/manual/en/function.utf8-decode.php
518	 * and $bom_be parameter added.
668	 * Set the decimal separator. Only used by PHPExcel_Style_NumberFormat::toFormattedString()
669	 * to format output by PHPExcel_Writer_HTML and PHPExcel_Writer_PDF
670	 *
700	 * Set the thousands separator. Only used by PHPExcel_Style_NumberFormat::toFormattedString()
701	 * to format output by PHPExcel_Writer_HTML and PHPExcel_Writer_PDF
702	 *
732	 * Set the currency code. Only used by PHPExcel_Style_NumberFormat::toFormattedString()
733	 *		to format output by PHPExcel_Writer_HTML and PHPExcel_Writer_PDF
734	 *
Hash.php https://bitbucket.org/arkross/venus | PHP | 854 lines
1<?php
2/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
3
4namespace PHPSecLib;
5
6/**
7 * Pure-PHP implementations of keyed-hash message authentication codes (HMACs) and various cryptographic hashing functions.
8 *
15 *
16 * PHP versions 4 and 5
17 *
22 * <code>
23 * <?php
24 *    include('Crypt/Hash.php');
50 * @package    Crypt_Hash
51 * @author     Jim Wigginton <terrafrost@php.net>
52 * @copyright  MMVII Jim Wigginton
AMFSerializer.php https://bitbucket.org/fxrialab/tickets | PHP | 1,048 lines
587			}
588			else if(AMFPHP_PHP5 && $className == 'domdocument')
589			{
786		{
787			$this->outBuffer .= chr($d >> 14 & 0x7f | 0x80) . chr($d >> 7 & 0x7f | 0x80) . chr($d & 0x7f);
788		} 
950		{
951			return chr($d >> 7 & 0x7f | 0x80) . chr($d & 0x7f);
952		}
954		{
955			return chr($d >> 14 & 0x7f | 0x80) . chr($d >> 7 & 0x7f | 0x80) . chr($d & 0x7f);
956		} 
958		{
959			return chr($d >> 22 & 0x7f | 0x80) . chr($d >> 15 & 0x7f | 0x80) . 
960				   chr($d >> 8 & 0x7f | 0x80) . chr($d & 0xff);
AMFSerializer.php https://bitbucket.org/fxrialab/tickets | PHP | 1,048 lines
587			}
588			else if(AMFPHP_PHP5 && $className == 'domdocument')
589			{
786		{
787			$this->outBuffer .= chr($d >> 14 & 0x7f | 0x80) . chr($d >> 7 & 0x7f | 0x80) . chr($d & 0x7f);
788		} 
950		{
951			return chr($d >> 7 & 0x7f | 0x80) . chr($d & 0x7f);
952		}
954		{
955			return chr($d >> 14 & 0x7f | 0x80) . chr($d >> 7 & 0x7f | 0x80) . chr($d & 0x7f);
956		} 
958		{
959			return chr($d >> 22 & 0x7f | 0x80) . chr($d >> 15 & 0x7f | 0x80) . 
960				   chr($d >> 8 & 0x7f | 0x80) . chr($d & 0xff);
getid3.putid3.php http://nukeviet-music.googlecode.com/svn/trunk/ | PHP | 1,647 lines
14		// %abcd0000
15		$flag .= Bool2IntString($Unsynchronisation); // a - Unsynchronisation
16		$flag .= Bool2IntString($ExtendedHeader);    // b - Extended header
21		// %abc00000
22		$flag .= Bool2IntString($Unsynchronisation); // a - Unsynchronisation
23		$flag .= Bool2IntString($ExtendedHeader);    // b - Extended header
52		$flag2 .= Bool2IntString($Encryption);          // m - Encryption (TRUE == encrypted)
53		$flag2 .= Bool2IntString($Unsynchronisation);   // n - Unsynchronisation (TRUE == unsynchronised)
54		$flag2 .= Bool2IntString($DataLengthIndicator); // p - Data length indicator (TRUE == data length indicator added)
166				} else {
167					$framedata .= str_replace(chr(0), '', $frame_data['ownerid']).chr(0);
168					$framedata .= substr($frame_data['data'], 0, 64); // max 64 bytes - truncate anything longer
853				// The private data      <binary data>
854				$framedata .= str_replace(chr(0), '', $frame_data['ownerid']).chr(0);
855				$framedata .= $frame_data['data'];
fsource_PHPExcel_Shared__PHPExcelSharedString.php.html git://github.com/shimondoodkin/node_spreadsheet.git | HTML | 750 lines
60<h1 align="center">Source for file String.php</h1>
61<p>Documentation is available at <a href="../PHPExcel_Shared/_PHPExcel---Shared---String.php.html">String.php</a></p>
62<div class="src-code">
371<li><div class="src-line"><a name="a311"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-comm">//&nbsp;CUSTOM:&nbsp;IBM&nbsp;AIX&nbsp;iconv()&nbsp;does&nbsp;not&nbsp;work</span></div></li>
372<li><div class="src-line"><a name="a312"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if&nbsp;</span><span class="src-sym">(&nbsp;</span><a href="http://www.php.net/defined">defined</a><span class="src-sym">(</span><span class="src-str">'PHP_OS'</span><span class="src-sym">)&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">@</span><a href="http://www.php.net/stristr">stristr</a><span class="src-sym">(</span><span class="src-id">PHP_OS</span><span class="src-sym">,&nbsp;</span><span class="src-str">'AIX'</span><span class="src-sym">)</span></div></li>
373<li><div class="src-line"><a name="a313"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&amp;&amp;&nbsp;<a href="http://www.php.net/defined">defined</a><span class="src-sym">(</span><span class="src-str">'ICONV_IMPL'</span><span class="src-sym">)&nbsp;</span>&amp;&amp;&nbsp;<span class="src-sym">(</span><span class="src-sym">@</span><a href="http://www.php.net/strcasecmp">strcasecmp</a><span class="src-sym">(</span><span class="src-id">ICONV_IMPL</span><span class="src-sym">,&nbsp;</span><span class="src-str">'unknown'</span><span class="src-sym">)&nbsp;</span>==&nbsp;<span class="src-num">0</span><span class="src-sym">)</span></div></li>
398<li><div class="src-line"><a name="a338"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li>
399<li><div class="src-line"><a name="a339"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">public&nbsp;</span><span class="src-key">static&nbsp;</span><span class="src-key">function&nbsp;</span><a href="../PHPExcel_Shared/PHPExcel_Shared_String.html#methodControlCharacterOOXML2PHP">ControlCharacterOOXML2PHP</a><span class="src-sym">(</span><span class="src-var">$value&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li>
400<li><div class="src-line"><a name="a340"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-id">self</span><span class="src-sym">::</span><span class="src-var">$_controlCharacters</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li>
420<li><div class="src-line"><a name="a360"></a><span class="src-doc">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</span></div></li>
421<li><div class="src-line"><a name="a361"></a>&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">public&nbsp;</span><span class="src-key">static&nbsp;</span><span class="src-key">function&nbsp;</span><a href="../PHPExcel_Shared/PHPExcel_Shared_String.html#methodControlCharacterPHP2OOXML">ControlCharacterPHP2OOXML</a><span class="src-sym">(</span><span class="src-var">$value&nbsp;</span>=&nbsp;<span class="src-str">''</span><span class="src-sym">)&nbsp;</span><span class="src-sym">{</span></div></li>
422<li><div class="src-line"><a name="a362"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">if</span><span class="src-sym">(</span><span class="src-key">empty</span><span class="src-sym">(</span><span class="src-id">self</span><span class="src-sym">::</span><span class="src-var">$_controlCharacters</span><span class="src-sym">))&nbsp;</span><span class="src-sym">{</span></div></li>
646<li><div class="src-line"><a name="a586"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$fractionFormula&nbsp;</span>=&nbsp;<span class="src-str">'='</span>.<span class="src-var">$sign</span>.<span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">2</span><span class="src-sym">]</span>.<span class="src-var">$sign</span>.<span class="src-var">$match</span><span class="src-sym">[</span><span class="src-num">3</span><span class="src-sym">]</span><span class="src-sym">;</span></div></li>
647<li><div class="src-line"><a name="a587"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-var">$operand&nbsp;</span>=&nbsp;<span class="src-id"><a href="../PHPExcel_Calculation/PHPExcel_Calculation.html">PHPExcel_Calculation</a></span><span class="src-sym">::</span><a href="../PHPExcel_Calculation/PHPExcel_Calculation.html#methodgetInstance">getInstance</a><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">-&gt;</span><span class="src-id">_calculateFormulaValue</span><span class="src-sym">(</span><span class="src-var">$fractionFormula</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
648<li><div class="src-line"><a name="a588"></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="src-key">return&nbsp;</span><span class="src-id">true</span><span class="src-sym">;</span></div></li>
getid3.lib.php https://bitbucket.org/DESURE/dcms.git | PHP | 1,380 lines
85			if (!$hasINT64 && !defined('PHP_INT_MIN')) {
86				define('PHP_INT_MIN', ~PHP_INT_MAX);
87			}
89		// if integers are 64-bit - no other check required
90		if ($hasINT64 || (($num <= PHP_INT_MAX) && ($num >= PHP_INT_MIN))) {
91			return true;
385		// written by kcØhireability*com
386		// taken from http://www.php.net/manual/en/function.array-merge-recursive.php
387		if (!is_array($array1) || !is_array($array2)) {
1346		if (GETID3_OS_ISWINDOWS) {
1347			if (class_exists('COM')) { // From PHP 5.3.15 and 5.4.5, COM and DOTNET is no longer built into the php core.you have to add COM support in php.ini:
1348				$filesystem = new COM('Scripting.FileSystemObject');
1368	/**
1369	* Workaround for Bug #37268 (https://bugs.php.net/bug.php?id=37268)
1370	* @param string $path A path.
BigInteger.php https://bitbucket.org/ttalov/fgcu_pci.git | PHP | 3,553 lines
524                    $temp = bcmod($current, '16777216');
525                    $value = chr($temp >> 16) . chr($temp >> 8) . chr($temp) . $value;
526                    $current = bcdiv($current, '16777216', 0);
710     * Although you can call Math_BigInteger::__toString() directly in PHP5, you cannot call Math_BigInteger::__clone()
711     * directly in PHP5.  You can in PHP4 since it's not a magic method, but in PHP5, you have to call it by using the PHP5
712     * only syntax of $y = clone $x.  As such, if you're trying to write an application that works on both PHP4 and PHP5,
2801        // generate as many leading 1's as we need to.
2802        $leading_ones = chr((1 << ($new_bits & 0x7)) - 1) . str_repeat(chr(0xFF), $new_bits >> 3);
2803        $this->_base256_lshift($leading_ones, $current_bits);
2910            $precision = 8 * strlen($bits) - 8 + $i;
2911            $mask = chr((1 << ($precision & 0x7)) - 1) . str_repeat(chr(0xFF), $precision >> 3);
2912        }
3047
3048        // gmp_nextprime() requires PHP 5 >= 5.2.0 per <http://php.net/gmp-nextprime>.
3049        if ( MATH_BIGINTEGER_MODE == MATH_BIGINTEGER_MODE_GMP && function_exists('gmp_nextprime') ) {
Hash.php https://bitbucket.org/ttalov/fgcu_pci.git | PHP | 825 lines
1<?php
2/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
4/**
5 * Pure-PHP implementations of keyed-hash message authentication codes (HMACs) and various cryptographic hashing functions.
6 *
13 *
14 * PHP versions 4 and 5
15 *
20 * <code>
21 * <?php
22 *    include('Crypt/Hash.php');
51 * @package    Crypt_Hash
52 * @author     Jim Wigginton <terrafrost@php.net>
53 * @copyright  MMVII Jim Wigginton
54 * @license    http://www.opensource.org/licenses/mit-license.html  MIT License
55 * @version    $Id: Hash.php,v 1.6 2009/11/23 23:37:07 terrafrost Exp $
56 * @link       http://phpseclib.sourceforge.net
Cpdf.php https://bitbucket.org/1blankz7/bibioteka.git | PHP | 4,612 lines
1645			// figure out the additional paramaters required
1646			$pad =	chr(0x28) .chr(0xBF) .chr(0x4E) .chr(0x5E) .chr(0x4E) .chr(0x75) .chr(0x8A) .chr(0x41)
1647 						.chr(0x64) .chr(0x00) .chr(0x4E) .chr(0x56) .chr(0xFF) .chr(0xFA) .chr(0x01) .chr(0x08)
1647 						.chr(0x64) .chr(0x00) .chr(0x4E) .chr(0x56) .chr(0xFF) .chr(0xFA) .chr(0x01) .chr(0x08)
1648 						.chr(0x2E) .chr(0x2E) .chr(0x00) .chr(0xB6) .chr(0xD0) .chr(0x68) .chr(0x3E) .chr(0x80)
1649 						.chr(0x2F) .chr(0x0C) .chr(0xA9) .chr(0xFE) .chr(0x64) .chr(0x53) .chr(0x69) .chr(0x7A);
1676			// now make the u value, phew.
1677			$tmp =	$this->md5_16($user.$ovalue.chr($options['p']) .chr(255) .chr(255) .chr(255) .$this->fileIdentifier);
1678
1731		}
1732		$tmp.=	chr(hexdec(substr($hex, 4, 2))) .chr(hexdec(substr($hex, 2, 2))) .chr(hexdec(substr($hex, 0, 2))) .chr(0) .chr(0);
1733		$key =	$this->md5_16($tmp);
4086		if	(!$error) {
4087			$header =	chr(137) .chr(80) .chr(78) .chr(71) .chr(13) .chr(10) .chr(26) .chr(10);
4088			if	(mb_substr($data, 0, 8, '8bit') !=	$header) {
BigInteger.php https://bitbucket.org/studiobreakfast/sync.git | PHP | 3,551 lines
522                    $temp = bcmod($current, '16777216');
523                    $value = chr($temp >> 16) . chr($temp >> 8) . chr($temp) . $value;
524                    $current = bcdiv($current, '16777216', 0);
708     * Although you can call Math_BigInteger::__toString() directly in PHP5, you cannot call Math_BigInteger::__clone()
709     * directly in PHP5.  You can in PHP4 since it's not a magic method, but in PHP5, you have to call it by using the PHP5
710     * only syntax of $y = clone $x.  As such, if you're trying to write an application that works on both PHP4 and PHP5,
2799        // generate as many leading 1's as we need to.
2800        $leading_ones = chr((1 << ($new_bits & 0x7)) - 1) . str_repeat(chr(0xFF), $new_bits >> 3);
2801        $this->_base256_lshift($leading_ones, $current_bits);
2908            $precision = 8 * strlen($bits) - 8 + $i;
2909            $mask = chr((1 << ($precision & 0x7)) - 1) . str_repeat(chr(0xFF), $precision >> 3);
2910        }
3045
3046        // gmp_nextprime() requires PHP 5 >= 5.2.0 per <http://php.net/gmp-nextprime>.
3047        if ( MATH_BIGINTEGER_MODE == MATH_BIGINTEGER_MODE_GMP && function_exists('gmp_nextprime') ) {
Hash.php https://bitbucket.org/studiobreakfast/sync.git | PHP | 824 lines
1<?php
2/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
4/**
5 * Pure-PHP implementations of keyed-hash message authentication codes (HMACs) and various cryptographic hashing functions.
6 *
13 *
14 * PHP versions 4 and 5
15 *
20 * <code>
21 * <?php
22 *    include('Crypt/Hash.php');
51 * @package    Crypt_Hash
52 * @author     Jim Wigginton <terrafrost@php.net>
53 * @copyright  MMVII Jim Wigginton
54 * @license    http://www.opensource.org/licenses/mit-license.html  MIT License
55 * @version    $Id: Hash.php,v 1.6 2009/11/23 23:37:07 terrafrost Exp $
56 * @link       http://phpseclib.sourceforge.net
barcodes.php https://bitbucket.org/izubizarreta/https-bitbucket.org-bityvip.git | PHP | 1,980 lines
457		$encode = array(
458			chr(0) => chr(131).'U', chr(1) => chr(128).'A', chr(2) => chr(128).'B', chr(3) => chr(128).'C',
459			chr(4) => chr(128).'D', chr(5) => chr(128).'E', chr(6) => chr(128).'F', chr(7) => chr(128).'G',
461			chr(12) => chr(128).'L', chr(13) => chr(128).'M', chr(14) => chr(128).'N', chr(15) => chr(128).'O',
462			chr(16) => chr(128).'P', chr(17) => chr(128).'Q', chr(18) => chr(128).'R', chr(19) => chr(128).'S',
463			chr(20) => chr(128).'T', chr(21) => chr(128).'U', chr(22) => chr(128).'V', chr(23) => chr(128).'W',
463			chr(20) => chr(128).'T', chr(21) => chr(128).'U', chr(22) => chr(128).'V', chr(23) => chr(128).'W',
464			chr(24) => chr(128).'X', chr(25) => chr(128).'Y', chr(26) => chr(128).'Z', chr(27) => chr(131).'A',
465			chr(28) => chr(131).'B', chr(29) => chr(131).'C', chr(30) => chr(131).'D', chr(31) => chr(131).'E',
472			chr(56) => '8', chr(57) => '9', chr(58) => chr(129).'Z', chr(59) => chr(131).'F',
473			chr(60) => chr(131).'G', chr(61) => chr(131).'H', chr(62) => chr(131).'I', chr(63) => chr(131).'J',
474			chr(64) => chr(131).'V', chr(65) => 'A', chr(66) => 'B', chr(67) => 'C',
480			chr(88) => 'X', chr(89) => 'Y', chr(90) => 'Z', chr(91) => chr(131).'K',
481			chr(92) => chr(131).'L', chr(93) => chr(131).'M', chr(94) => chr(131).'N', chr(95) => chr(131).'O',
482			chr(96) => chr(131).'W', chr(97) => chr(130).'A', chr(98) => chr(130).'B', chr(99) => chr(130).'C',
BigInteger.php https://bitbucket.org/cbeier/test.git | PHP | 3,553 lines
524                    $temp = bcmod($current, '16777216');
525                    $value = chr($temp >> 16) . chr($temp >> 8) . chr($temp) . $value;
526                    $current = bcdiv($current, '16777216', 0);
710     * Although you can call Math_BigInteger::__toString() directly in PHP5, you cannot call Math_BigInteger::__clone()
711     * directly in PHP5.  You can in PHP4 since it's not a magic method, but in PHP5, you have to call it by using the PHP5
712     * only syntax of $y = clone $x.  As such, if you're trying to write an application that works on both PHP4 and PHP5,
2801        // generate as many leading 1's as we need to.
2802        $leading_ones = chr((1 << ($new_bits & 0x7)) - 1) . str_repeat(chr(0xFF), $new_bits >> 3);
2803        $this->_base256_lshift($leading_ones, $current_bits);
2910            $precision = 8 * strlen($bits) - 8 + $i;
2911            $mask = chr((1 << ($precision & 0x7)) - 1) . str_repeat(chr(0xFF), $precision >> 3);
2912        }
3047
3048        // gmp_nextprime() requires PHP 5 >= 5.2.0 per <http://php.net/gmp-nextprime>.
3049        if ( MATH_BIGINTEGER_MODE == MATH_BIGINTEGER_MODE_GMP && function_exists('gmp_nextprime') ) {
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21