NineSec Team Shell
Server IP : 184.107.3.203  /  Your IP : 216.73.216.51
Web Server : Apache
System : Linux dedicated2.avenfashion.com.ph 4.18.0-553.40.1.el8_10.x86_64 #1 SMP Mon Feb 10 12:11:18 EST 2025 x86_64
User : adminteladeoro ( 1015)
PHP Version : 8.2.28
Disable Function : exec,passthru,shell_exec,system
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /usr/share/doc/cpanel-php83-text-figlet/docs/examples/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //usr/share/doc/cpanel-php83-text-figlet/docs/examples/hello_world.php
<?php

/* UTF-8 convert to FIGlet Unicode */
/* iconv PHP module required */
function utf8tofiglet($str)
{
    // escape %u
    $str = str_replace('%u', sprintf('%%%%u%04X', ord('u')), $str);

    if (function_exists('iconv')) {
        $str = iconv('utf-8', 'ucs-2be', $str);
        $out = '';

        for ($i = 0, $len = strlen($str); $i<$len; $i++) {
            $code = ord($str[$i++]) * 256 + ord($str[$i]);

            $out .= $code < 128 ? $str[$i] : sprintf('%%u%04X', $code);
        }

        return $out;
    }

    return $str;
}

require_once 'Text/Figlet.php';

$figlet = new Text_Figlet();
$error  = $figlet->LoadFont('makisupa.flf');
if (PEAR::isError($error)) {
    echo 'Error: ' . $error->getMessage() . "\n";
} else {
    echo $figlet->LineEcho(utf8tofiglet('Hello, world!')) . "\n";
}
?>

NineSec Team - 2022