Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
--TEST-- Test gmstrftime() function : usage variation - Checking day related formats which..
Decoded Output download
--TEST--
Test gmstrftime() function : usage variation - Checking day related formats which are supported other than on Windows.
--SKIPIF--
<?php
if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN') {
die("skip Test is not valid for Windows");
}
?>
--FILE--
<?php
echo "*** Testing gmstrftime() : usage variation ***
";
// Initialise function arguments not being substituted (if any)
$timestamp = gmmktime(8, 8, 8, 8, 8, 2008);
setlocale(LC_ALL, "en_US");
date_default_timezone_set("Asia/Calcutta");
echo "
-- Testing gmstrftime() function with Day of the month as decimal single digit format --
";
$format = "%e";
var_dump( gmstrftime($format) );
var_dump( gmstrftime($format, $timestamp) );
?>
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
-- Testing gmstrftime() function with Day of the month as decimal single digit format --
Deprecated: Function gmstrftime() is deprecated in %s on line %d
string(%d) "%s"
Deprecated: Function gmstrftime() is deprecated in %s on line %d
string(2) " 8"
Did this file decode correctly?
Original Code
--TEST--
Test gmstrftime() function : usage variation - Checking day related formats which are supported other than on Windows.
--SKIPIF--
<?php
if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN') {
die("skip Test is not valid for Windows");
}
?>
--FILE--
<?php
echo "*** Testing gmstrftime() : usage variation ***\n";
// Initialise function arguments not being substituted (if any)
$timestamp = gmmktime(8, 8, 8, 8, 8, 2008);
setlocale(LC_ALL, "en_US");
date_default_timezone_set("Asia/Calcutta");
echo "\n-- Testing gmstrftime() function with Day of the month as decimal single digit format --\n";
$format = "%e";
var_dump( gmstrftime($format) );
var_dump( gmstrftime($format, $timestamp) );
?>
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
-- Testing gmstrftime() function with Day of the month as decimal single digit format --
Deprecated: Function gmstrftime() is deprecated in %s on line %d
string(%d) "%s"
Deprecated: Function gmstrftime() is deprecated in %s on line %d
string(2) " 8"
Function Calls
None |
Stats
MD5 | 439a6fcab81ed972234c4c474ffc390a |
Eval Count | 0 |
Decode Time | 87 ms |