WOW...so much simpler..thank you very much!! Cheers Phil
<BLOCKQUOTE style='PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #A0C6E5 2px solid; MARGIN-RIGHT: 0px'><font style='FONT-SIZE:11px;FONT-FAMILY:tahoma,sans-serif'><hr color=#A0C6E5 size=1> From: <i>Burhan Khalid <[EMAIL PROTECTED]></i><br>To: <i>Philippe Reynolds <[EMAIL PROTECTED]></i><br>CC: <i>php-general@lists.php.net</i><br>Subject: <i>Re: [PHP] Socket functions</i><br>Date: <i>Tue, 30 Aug 2005 09:49:22 +0300</i><br>>Philippe Reynolds wrote:<br>>>Greetings,<br>>><br>>>When I do an ifconfig in unix, I see the the IP address for the my <br>>>ethernet. It follows something called inet.<br>>><br>>>Would anyone know who to manipulate the socket functions to be able <br>>>to extract the inet IP address fromt the eth0 section??<br>><br>><?php<br>><br>> exec('ifconfig eth0 | grep inet',$output);<br>>preg_match("|[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}|",$output[0],$matches);<br>> echo $matches[0];<br>><br>>?><br></font></BLOCKQUOTE>
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php