[ create a new paste ] login | about

Link: http://codepad.org/TCNh7tGI    [ raw code | output | fork ]

PHP, pasted on Nov 4:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<?php
$code="class evalTest{
    function f1(){
        echo 'f1';
        \$this->f2();
    }
    function f2(){
        echo 'f2';
    }
}

\$x=new evalTest();
\$x->f2();
\$x->f1();";


eval($code);
echo 'test';


Output:
1
f2f1f2test


Create a new paste based on this one


Comments: