mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
39 lines
1.1 KiB
PHP
39 lines
1.1 KiB
PHP
--TEST--
|
|
eval() test
|
|
--FILE--
|
|
<?php
|
|
|
|
eval("function test() { echo \"hey, this is a function inside an eval()!\\n\"; }");
|
|
|
|
$i=0;
|
|
while ($i<10) {
|
|
eval("echo \"hey, this is a regular echo'd eval()\\n\";");
|
|
test();
|
|
$i++;
|
|
}
|
|
|
|
eval('-');
|
|
--EXPECTF--
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
hey, this is a regular echo'd eval()
|
|
hey, this is a function inside an eval()!
|
|
|
|
Parse error: syntax error, unexpected %s in %s019.php(12) : eval()'d code on line 1
|