Multi-line code in PHP interactive shell -


I'm learning to use PHP interactive shell, but I'm having trouble with multi-line code.

Using backslashes such as Unix shells does not work. What am i doing

  php> function test () {\ php {echo "test"; \ Php {} \ php> testing(); PHP Parse error: syntax error, expected T_STRING in unexpected T_ECHO, php shell code on line 2  

Just is not saved:

  php> function test () php> {PHP {resonant "test"; Php {} php> testing(); Test  

However, you will have problems in some cases, such as:

  php> if (conditional) php> {Php {// ... php {} php> Other PHP & gt; {Php {// ... php {}  

Thinks that before he sees the other, you get "unexpected T_ELSE" In this situation, Is nearby:

  php> if (conditional) php> {PHP  

Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -