Re: endless repeat

From: Date: Sat, 23 Dec 2000 17:56:31 +0000
Subject: Re: endless repeat
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-4641@lists.php.net to get a copy of this message
At 18:28 23.12.2000 +0100, dulidel the programmer wrote:
how can i make an endless repeat
you should rethink the design of your code, relying on an endless loop is *never* a good idea. do not run this code from your webserver. <?php ini_set("max_execution_time", 0); $handle = fopen("php://stdin","r"); while(true) { print "\ndo you want to quit? "; if(trim(fgets($handle, 4)) == "y")
        break;
else
        continue;
} fclose($handle); ?> daniel /*-- daniel beulshausen - daniel@php4win.de using php on windows? http://www.php4win.de

« previous php.windows (#4641) next »