php has a interactive shell.
Just input
php -a
in your shell.
$ php -a Interactive shell
php > $a=array(“name”=>”ting”); php > $a[]=3; php > print_r($a); Array ( [name] => ting [0] => 3 ) php >
Another way to try your script is using:
php -f yourPHP.php
$name = "ting";
if($name == "ting){
print "hello";
}
