Re: get a list of clients with PHP

From: Date: Sun, 21 Jul 2002 20:53:35 +0000
Subject: Re: get a list of clients with PHP
Groups: php.general 
Request: Send a blank email to php-general+get-108755@lists.php.net to get a copy of this message
>Hello, > >there is a problem in a enterprise LAN: >On each PC runs a Client, which waits at a haven for messages. >With fsockopen(); messages are sent to all existing Clients. >Functioned only, if one knows, the which Clients are switched on. >If the Script meets a IP, whose PC is switched off, it dies. >All following IP's receives no more message. > >My problem: >How can I receive a list of the PC's switched on at present with PHP? >System calls are not a genuine solution. >The Script is not only to work under Linux. I don't think fsockopen's failure to open a socket will "kill" a PHP script... Show us source code for that bit, and the loop you use to visit all the PC's... Also be sure you are setting a reasonable time-out on the fsockopen (http://php.net/fsockopen) as well as on PHP itself (http://php.net/set_time_limit) Try adding as much error-checking code as you can around the fsockopen functions calls, and log the stuff to a file or something where you can get it. http://php.net/error_log -- Like Music? http://l-i-e.com/artists.htm

« previous php.general (#108755) next »