Does PHP have anything like Ruby's irb?
Run php -a
in the command-line. But this does not work on Windows.
For Windows, you may want to try phpa-norl.
Yes, there is a way: php -a, -a means interactive shell
php -a is the closest thing I know of but it's not quite like irb. irb will execute each line at a time. php -a will wait until you press ctrl-D (for end of line) and will then execute all lines.