Page 1 of 1

Input Lines

Posted: Wed Oct 29, 2008 2:57 pm
by Syntac
I'm writing a command-line PHP chat system. All the little details, nonblocking stdin, all that, are working fine. However: When one client (call him Joe) writes a message and another client (Bob) is in the middle of typing something, Bob's message-in-progress gets clobbered.

I've done an extensive search and found nothing on this. It may be possible to use escape sequences (surprisingly, they work in PHP), but I'd rather have a less hacky, more software-independent solution.