Re: [PHP] php + lynx + grep

2004-04-06 Thread Brian L. Ollom
> Functions like system, exec etc aren't supported by most ISP
> ( at least over here in germany ). But you might give 
> 
> file_get_contents();
> file();
> ...
> 
> a look as they can read the output of HTTP request which might
> be easier:
> 
> $var = file
> ( 'http://weather.noaa.gov/weather/current/KTOL.html' );
> foreach ( $var AS $line ) {
> if ( preg_match( "41-35-19N" , $var ) )
>... etc pp
> }

I am the ISP, but I'll try that and see if it helps...  (o;


| Brian Ollom  |   |
| NiteHawke.Com|  http://www.nitehawke.com/|
| An Authorized Firefly Dealer |  email  [EMAIL PROTECTED]  |


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] php + lynx + grep

2004-04-06 Thread Brian L. Ollom
> Try
> 
> $output = `lynx --source 
> http://weather.noaa.gov/weather/current/KTOL.html |grep -v
> '41-35-19N' |grep TOL | head -n 1`
> 
> Those are backticks, not single quotes surrounding the
> command.

Backticks didn't work either.

I got it to work by using a cron to > the info into a text file
and then include()'d the text file in the website, but I'd
rather not have to rely on the cron job if I don't have to.


| Brian Ollom  |   |
| NiteHawke.Com|  http://www.nitehawke.com/|
| An Authorized Firefly Dealer |  email  [EMAIL PROTECTED]  |


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] php + lynx + grep

2004-04-06 Thread Brian L. Ollom
lynx --source http://weather.noaa.gov/weather/current/KTOL.html
|grep -v '41-35-19N' |grep TOL | head -n 1

I need to get the output of the above command for a web site I'm
working on.  I've tried exec(), system() and neither seems to
work.

It's output should be something like this(it changes hourly):
KTOL 031452Z 28013KT
  10SM CLR 10/01 A2977 RMK AO2 SLP086 T0106 58015

Help!


| Brian Ollom  |   |
| NiteHawke.Com|  http://www.nitehawke.com/|
| An Authorized Firefly Dealer |  email  [EMAIL PROTECTED]  |

ForPilot's - Software for your piloting needs!
http://www.forpilots.com/
Great Deals on Great Pilot Supplies!
http://www.acespilotshop.com/cgi-bin/ares.cgi?ID=240400532
Want deals on other great stuff?  Click here!
http://www.dollardays.com/index.asp?affilid=385

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: php + lynx + grep

2004-04-06 Thread Brian L. Ollom
> lynx --source
> http://weather.noaa.gov/weather/current/KTOL.html | grep -v
> '41-35-19N' |grep TOL | head -n 1
>
> I need to get the output of the above command for a web site
> I'm working on.  I've tried exec(), system() and neither seems
> to work.
>
> It's output should be something like this(it changes hourly):
> KTOL 031452Z 28013KT
>   10SM CLR 10/01 A2977 RMK AO2 SLP086 T0106 58015

It works fine on the command line, but won't show any info on
the site.


| Brian Ollom  |   |
| NiteHawke.Com|  http://www.nitehawke.com/|
| An Authorized Firefly Dealer |  email  [EMAIL PROTECTED]  |


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] php + lynx + grep

2004-04-06 Thread Brian L. Ollom
lynx --source http://weather.noaa.gov/weather/current/KTOL.html
|grep -v '41-35-19N' |grep TOL | head -n 1

I need to get the output of the above command for a web site I'm
working on.  I've tried exec(), system() and neither seems to
work.

It's output should be something like this(it changes hourly):
KTOL 061152Z 23004KT 10SM
  CLR 00/M07 A3007 RMK AO2 SLP187 T1072 10017 21033 53005

Help!


| Brian Ollom  |   |
| NiteHawke.Com|  http://www.nitehawke.com/|
| An Authorized Firefly Dealer |  email  [EMAIL PROTECTED]  |


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] php + lynx + grep

2004-04-06 Thread Brian L. Ollom
lynx --source http://weather.noaa.gov/weather/current/KTOL.html |grep -v
'41-35-19N' |grep TOL | head -n 1

I need to get the output of the above command for a web site I'm
working on.  I've tried exec(), system() and neither seems to
work.

It's output should be something like this(it changes hourly):
KTOL 031452Z 28013KT
  10SM CLR 10/01 A2977 RMK AO2 SLP086 T0106 58015

Help!


| Brian Ollom  |   |
| NiteHawke.Com|  http://www.nitehawke.com/|
| An Authorized Firefly Dealer |  email  [EMAIL PROTECTED]  |


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php