Hi,
Tuesday, July 29, 2003, 3:11:43 AM, you wrote:
CZ> * Thus wrote Tom Rogers ([EMAIL PROTECTED]):
>> Hi,
>>
>> Monday, July 28, 2003, 4:29:46 PM, you wrote:
>> >>Try this:
>> >>> >>exec('ipconfig',$catch);
>> >>foreach($catch as $line){
>> >>if(eregi('IP Address',$line)){
>> >>
* Thus wrote Tom Rogers ([EMAIL PROTECTED]):
> Hi,
>
> Monday, July 28, 2003, 4:29:46 PM, you wrote:
> >>Try this:
> >> >>exec('ipconfig',$catch);
> >>foreach($catch as $line){
> >>if(eregi('IP Address',$line)){
> >>list($t,$ip) = split(':',$line);
> >>echo
<[EMAIL PROTECTED]>
Mark:
> For Win9x, use winipcfg instead of ipconfig.
winipcfg is a windows-based utility, which can't work with PHP.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
For Win9x, use winipcfg instead of ipconfig.
--- Chris Lee <[EMAIL PROTECTED]> wrote:
> >Try this:
> > >exec('ipconfig',$catch);
> >foreach($catch as $line){
> >if(eregi('IP Address',$line)){
> >list($t,$ip) = split(':',$line);
> >echo 'IP is '.$ip."\n";
> >
Hi,
Monday, July 28, 2003, 4:29:46 PM, you wrote:
>>Try this:
>>>exec('ipconfig',$catch);
>>foreach($catch as $line){
>>if(eregi('IP Address',$line)){
>>list($t,$ip) = split(':',$line);
>>echo 'IP is '.$ip."\n";
>>}
>>}
>>?>
CL> Thanks Tom, but I th
>Try this:
>exec('ipconfig',$catch);
>foreach($catch as $line){
>if(eregi('IP Address',$line)){
>list($t,$ip) = split(':',$line);
>echo 'IP is '.$ip."\n";
>}
>}
>?>
Thanks Tom, but I think it only work for Win NT, how about Win 9x?
--
PHP General
Hi,
Monday, July 28, 2003, 12:21:06 PM, you wrote:
CL> How can I get the local Computer IP Address when running PHP program in
CL> Windows command line (i.e. php getmyip.php)
CL> ** Since the PHP did not are run on Webserver, so _SERVER["SERVER_ADDR"]
CL> won't work.
CL> Many thanks in advance
How can I get the local Computer IP Address when running PHP program in
Windows command line (i.e. php getmyip.php)
** Since the PHP did not are run on Webserver, so _SERVER["SERVER_ADDR"]
won't work.
Many thanks in advance.
Regards,
Chris
--
PHP General Mailing List (http://www.php.net/)
To u
8 matches
Mail list logo