RE: [PHP] Command line php

From: Date: Wed, 02 Apr 2003 02:09:26 +0000
Subject: RE: [PHP] Command line php
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-141913@lists.php.net to get a copy of this message
Try sending a control d to signify EOF, because fread will only read to end of file. But I wouldn't do 255 because you might want to enter more. Maybe stick a while !EOF in there. > -----Original Message----- > From: John Nichel [mailto:jnichel@by-tor.com] > Sent: Tuesday, April 01, 2003 6:01 PM > To: php-general@lists.php.net > Subject: Re: [PHP] Command line php > > > I did that orginally, but it waits for me to enter 255 characters before > closing the fread....no matter how many times I hit enter. > > > Benny Pedersen wrote: > > > >> On Wednesday 02 April 2003 03:17, John Nichel wrote: > >> > >>> if I do a... > >>> $name = fread ( STDIN, sizeof ( STDIN ) ); > >> > >> > >> > >> $name = fread ( STDIN, 255 ); > >> > >> tryit :) > >> > >> > > > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.general (#141913) next »