Reputation: 13682
I know that you can run php files from terminal with linux running PHP... I.e. "php script.php" ... But is there any program that allows you to directly input php into the terminal (through any intermediary program) and output the results? I.e. In terminal, testing php globals like getinfo(), etc..? Any help would be great, I'd like to test functions and commands through a sort of run-time terminal. Thanks!
Upvotes: 17
Views: 57225
Reputation: 16355
php -a
(as of PHP 5.1) should do what you want.
http://php.net/manual/en/features.commandline.interactive.php
Upvotes: 45
Reputation: 182
You might like a program called PHP Shell Terminal: http://sourceforge.net/projects/phpterm/
Upvotes: -2