You are here: CLI keyboard input not working in Windows XP « PHP Programming Language « IT news, forums, messages
CLI keyboard input not working in Windows XP

Posted by BDthatsme on 10/10/07 19:39

I have tried various ways to get input from the keyboard using the CLI
version of PHP on Windows XP SP2, and none of them seem to work. And I
can't find any info about it anywhere. (as in how or why except the
standard stuff) So I don't know if it is a problem with my system, or
PHP, or keyboard input using PHP CLI under Windows (XP), or what.

php -v gives:

PHP 5.1.6 (cli) (built: Aug 23 2006 16:35:53)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies

Theoretically, this line should work:

$text = fgets (STDIN, 1024);

It does prompt and allow input, but it doesn't return anything.

Even if I open the stream using fopen ("php://stdin", "r") and try to
read from that it doesn't work.

Any ideas or suggestions?

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация