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-- runkit_method_redefine() function and doc_comment --SKIPIF-- <?php if(!extension_..

Decoded Output download

--TEST--
runkit_method_redefine() function and doc_comment
--SKIPIF--
<?php if(!extension_loaded("runkit") || !RUNKIT_FEATURE_MANIPULATION) print "skip"; ?>
--INI--
display_errors=on
--FILE--
<?php
if (!defined('E_STRICT')) {
	define('E_STRICT', 0);
}
if (!defined('E_DEPRECATED')) {
	define('E_DEPRECATED', 0);
}
ini_set('error_reporting', E_ALL & (~E_DEPRECATED) & (~E_STRICT));

class runkit_class {
	/**
	 * old doc_comment
	 */
	function runkit_method($a) {
		echo "a is $a
";
	}
	function runkitMethod($a) {
		echo "a is $a
";
	}
}
runkit_method_redefine('runkit_class','runkit_method','$b', 'echo "b is $b
";', NULL, 'new doc_comment1');
runkit_method_redefine('runkit_class','runkitMethod','$b', 'echo "b is $b
";', NULL, 'new doc_comment2');
$r1 = new ReflectionMethod('runkit_class', 'runkit_method');
echo $r1->getDocComment(), "
";
$r2 = new ReflectionMethod('runkit_class', 'runkitMethod');
echo $r2->getDocComment(), "
";
?>
--EXPECT--
new doc_comment1
new doc_comment2

Did this file decode correctly?

Original Code

--TEST--
runkit_method_redefine() function and doc_comment
--SKIPIF--
<?php if(!extension_loaded("runkit") || !RUNKIT_FEATURE_MANIPULATION) print "skip"; ?>
--INI--
display_errors=on
--FILE--
<?php
if (!defined('E_STRICT')) {
	define('E_STRICT', 0);
}
if (!defined('E_DEPRECATED')) {
	define('E_DEPRECATED', 0);
}
ini_set('error_reporting', E_ALL & (~E_DEPRECATED) & (~E_STRICT));

class runkit_class {
	/**
	 * old doc_comment
	 */
	function runkit_method($a) {
		echo "a is $a\n";
	}
	function runkitMethod($a) {
		echo "a is $a\n";
	}
}
runkit_method_redefine('runkit_class','runkit_method','$b', 'echo "b is $b\n";', NULL, 'new doc_comment1');
runkit_method_redefine('runkit_class','runkitMethod','$b', 'echo "b is $b\n";', NULL, 'new doc_comment2');
$r1 = new ReflectionMethod('runkit_class', 'runkit_method');
echo $r1->getDocComment(), "\n";
$r2 = new ReflectionMethod('runkit_class', 'runkitMethod');
echo $r2->getDocComment(), "\n";
?>
--EXPECT--
new doc_comment1
new doc_comment2

Function Calls

extension_loaded 1

Variables

None

Stats

MD5 3229bd3ff3a98d5578e16292e1ab0eb8
Eval Count 0
Decode Time 97 ms