Re: Re: UDP Packet Writing

From: Date: Mon, 12 May 2003 12:39:24 +0000
Subject: Re: Re: UDP Packet Writing
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-147295@lists.php.net to get a copy of this message
Answered my own question, never mind, thanks very much again. On Mon, 2003-05-12 at 08:27, Adam Voigt wrote: > Wow, thanks. > > Only one question, what's the "CCLSC*" for? > > > On Thu, 2003-05-08 at 10:44, Hugh Bothwell wrote: > > > > <?php > > > > function SendUdpMsg($host, $port, $msg) { > > $udp = fsockopen("udp://$host", $port); > > fwrite($udp, $msg); > > fclose($udp); > > } > > > > function CommandStr($cmd, $ip, $port) { > > return pack( > > "CCLSC*", > > $cmd, > > 0, > > $ip, > > $port, > > 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 > > ); > > } > > > > SendUDPMsg( "127.0.0.1", 8001, > > CommandStr(3, ip2long("127.0.0.1"), 8002) > > ); > > ?> > -- > Adam Voigt (adam@cryptocomm.com) > Linux/Unix Network Administrator > The Cryptocomm Group -- Adam Voigt (adam@cryptocomm.com) Linux/Unix Network Administrator The Cryptocomm Group

« previous php.general (#147295) next »