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-- Bug #73998 (array_key_exists fails on arrays created by get_object_vars) --DESCRI..

Decoded Output download

--TEST--
Bug #73998 (array_key_exists fails on arrays created by get_object_vars)
--DESCRIPTION--
Properties of objects with numeric names should be accessible
--FILE--
<?php
$a = new stdClass;
$a->{1234} = "Numeric";
$a->a1234 = "String";

$properties = get_object_vars($a);
var_dump(array_key_exists(1234, $properties));
echo "Value: {$properties[1234]}
";

?>
--EXPECT--
bool(true)
Value: Numeric

Did this file decode correctly?

Original Code

--TEST--
Bug #73998 (array_key_exists fails on arrays created by get_object_vars)
--DESCRIPTION--
Properties of objects with numeric names should be accessible
--FILE--
<?php
$a = new stdClass;
$a->{1234} = "Numeric";
$a->a1234 = "String";

$properties = get_object_vars($a);
var_dump(array_key_exists(1234, $properties));
echo "Value: {$properties[1234]}\n";

?>
--EXPECT--
bool(true)
Value: Numeric

Function Calls

None

Variables

None

Stats

MD5 b745157ecf2828d853da61253ca6a177
Eval Count 0
Decode Time 79 ms