How to use the PHP interactive shell
interactive-shell, php, readline, ubuntu
Solution
Try installing phpsh. It is probably the easiest solution.
Steps (assuming dependencies are installed):
- `git clone https://github.com/facebook/phpsh`
- `cd phpsh`
- `sudo python setup.py install`
- `phpsh`
Problem
I'm using Ubuntu 12.04 (Precise Pangolin) 64 bit, and I want to use the PHP interactive shell: ``` php -a ``` But it doesn't seem to work very well, and a lot of syntax is incorrectly interpreted. When I run `php -a`, it displays: interactive mode enabled And just a cursor blinking. I'm using: PHP 5.4.13-2~precise+1 (cli) (built: Mar 21 2013 12:17:18) How do I use the PHP interactive shell?