I'm trying to write a PHP script that will basically send input to a process, and receive back its output. Specifically, I want write a script to interact with gnuchess in engine mode... where I send a move, and receive back the computer's move (or a message that my move was not legal). How would I go about doing this in PHP, any suggestions or pointers?
Thanks!
