Is there anyway to read from STDIN with PHP that is non blocking:
STDIN
I tried this:
stream_set_blocking(STDIN, false); echo fread(STDIN, 1);
Here's what I could come up with. It works fine in Linux, but on Windows, as soon as I hit a key, the input is buffered until enter is pressed. I don't know a way to disable buffering on a stream.