Author Topic: wxflyer.php help  (Read 1936 times)

0 Members and 1 Guest are viewing this topic.

Offline cospringswx

  • Forecaster
  • *****
  • Posts: 4136
    • Colorado Springs Weather
wxflyer.php help
« on: January 22, 2013, 05:45:17 PM »
I get the message below when I open wxflyer.php

Warning: fopen(./nws-forecast-discussion.txt) [function.fopen]: failed to open stream: Permission denied in /virtual/users/e17244-18991/web/wxflyer.php on line 413

Any ideas? I have permissions set to 666.
Line 413 is cache.


http://hayskansasweather.com/wxflyer.php




Ryan 

Colorado Springs, CO
www.cospringsweather.com
Davis Vantage Vue
Weather Display Software
Amcrest HD IP Camera

Offline jmcmurry

  • Jim McMurry
  • Forecaster
  • *****
  • Posts: 528
  • Davis Vantage Pro 2 Plus Wireless.
    • Juneau County Weather
Re: wxflyer.php help
« Reply #1 on: January 22, 2013, 05:58:58 PM »
It's working now.

- Jim

Forum Search and Google Can be Your Best Friends

Offline ALITTLEweird1

  • Mark
  • Global Moderator
  • Forecaster
  • *****
  • Posts: 923
    • North Bend Weather
Re: wxflyer.php help
« Reply #2 on: January 22, 2013, 08:15:12 PM »
Its there again..

Warning: fopen(./nws-forecast-discussion.txt) [function.fopen]: failed to open stream: Permission denied in /virtual/users/e17244-18991/web/wxflyer.php on line 413

Not really recommended, but try changing your nws-forecast-discussion.txt file to 777 in the permissions just to see if that works.
"Nature can do without man, but man cannot do without nature."


Software: WeatherDisplay
Hardware: Davis VP2 + VP2 Solar + VP2 UV + Lightning Detector + Logitech Webcam + Soil temp + Soil Moisture

Offline cospringswx

  • Forecaster
  • *****
  • Posts: 4136
    • Colorado Springs Weather
Re: wxflyer.php help
« Reply #3 on: January 22, 2013, 08:30:42 PM »
Sometimes it does it and sometimes it don't. Odd! Might leave it besides putting the permissions that high since its not recommend.

Thanks




Ryan 

Colorado Springs, CO
www.cospringsweather.com
Davis Vantage Vue
Weather Display Software
Amcrest HD IP Camera

Offline cospringswx

  • Forecaster
  • *****
  • Posts: 4136
    • Colorado Springs Weather
Re: wxflyer.php help
« Reply #4 on: January 22, 2013, 09:40:59 PM »
I found the problem I think. I have no nws-forecast-discussion.txt file on my server!




Ryan 

Colorado Springs, CO
www.cospringsweather.com
Davis Vantage Vue
Weather Display Software
Amcrest HD IP Camera

Offline Bunty

  • Forecaster
  • *****
  • Posts: 2432
  • Stillwater, home of Oklahoma State University
    • Welcome to Stillwater Weather
Re: wxflyer.php help
« Reply #5 on: January 24, 2013, 04:28:37 AM »
I found the problem I think. I have no nws-forecast-discussion.txt file on my server!

It still gives that warning problem sometimes.  On my flyer at http://stillwaterweather.com/wx/wxflyer.php  a forecast discussion never shows up even with a nws-forecast-discussion.txt file in place.  I've noticed forecast discussion isn't showing up on some of the other sites with flyers as well.

Also the 2nd home page using modified AltDashboard 6.95 at http://stillwaterweather.com/2ndhome.php

Offline cospringswx

  • Forecaster
  • *****
  • Posts: 4136
    • Colorado Springs Weather
Re: wxflyer.php help
« Reply #6 on: January 24, 2013, 02:32:55 PM »
I found the problem I think. I have no nws-forecast-discussion.txt file on my server!

It still gives that warning problem sometimes.  On my flyer at http://stillwaterweather.com/wx/wxflyer.php  a forecast discussion never shows up even with a nws-forecast-discussion.txt file in place.  I've noticed forecast discussion isn't showing up on some of the other sites with flyers as well.

Yours looks great with no errors. Could I just tell the script not to look for one so I won't have an error?




Ryan 

Colorado Springs, CO
www.cospringsweather.com
Davis Vantage Vue
Weather Display Software
Amcrest HD IP Camera

Offline Bunty

  • Forecaster
  • *****
  • Posts: 2432
  • Stillwater, home of Oklahoma State University
    • Welcome to Stillwater Weather
Re: wxflyer.php help
« Reply #7 on: January 24, 2013, 03:36:08 PM »
I found the problem I think. I have no nws-forecast-discussion.txt file on my server!

It still gives that warning problem sometimes.  On my flyer at http://stillwaterweather.com/wx/wxflyer.php  a forecast discussion never shows up even with a nws-forecast-discussion.txt file in place.  I've noticed forecast discussion isn't showing up on some of the other sites with flyers as well.

Yours looks great with no errors. Could I just tell the script not to look for one so I won't have an error?

Thanks.  Try putting two slashes at both ends of entry at around line 38 to look like this:
//$WRH_URL = 'http://forecast.weather.gov/product.php?site=NWS&issuedby=OUN&product=AFD&format=TXT&version=1&glossary=0';//

Also the 2nd home page using modified AltDashboard 6.95 at http://stillwaterweather.com/2ndhome.php

Offline cospringswx

  • Forecaster
  • *****
  • Posts: 4136
    • Colorado Springs Weather
Re: wxflyer.php help
« Reply #8 on: January 24, 2013, 03:48:52 PM »
I did that and I still get this...

Warning: fopen(./nws-forecast-discussion.txt) [function.fopen]: failed to open stream: Permission denied in /virtual/users/e17244-18991/web/wxflyer.php on line 413


When I first load the page it's fine but if you refresh the error comes back.




Ryan 

Colorado Springs, CO
www.cospringsweather.com
Davis Vantage Vue
Weather Display Software
Amcrest HD IP Camera

Offline ALITTLEweird1

  • Mark
  • Global Moderator
  • Forecaster
  • *****
  • Posts: 923
    • North Bend Weather
Re: wxflyer.php help
« Reply #9 on: January 24, 2013, 08:34:03 PM »
Are you sure you have the .txt file on your site? I cant see it here.. http://hayskansasweather.com/nws-forecast-discussion.txt

Here's what mine looks like... http://www.northbendweather.com/nws-forecast-discussion.txt
"Nature can do without man, but man cannot do without nature."


Software: WeatherDisplay
Hardware: Davis VP2 + VP2 Solar + VP2 UV + Lightning Detector + Logitech Webcam + Soil temp + Soil Moisture

Offline cospringswx

  • Forecaster
  • *****
  • Posts: 4136
    • Colorado Springs Weather
Re: wxflyer.php help
« Reply #10 on: January 24, 2013, 09:00:53 PM »
Are you sure you have the .txt file on your site? I cant see it here.. http://hayskansasweather.com/nws-forecast-discussion.txt

Here's what mine looks like... http://www.northbendweather.com/nws-forecast-discussion.txt

That's what I said. I don't.




Ryan 

Colorado Springs, CO
www.cospringsweather.com
Davis Vantage Vue
Weather Display Software
Amcrest HD IP Camera

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1152
Re: wxflyer.php help
« Reply #11 on: January 24, 2013, 09:24:07 PM »
Using notepad create a blank file and when saving the file, name it

nws-forecast-discussion.txt

Then upload it to your site and change the file permissions to 666.

Offline Bunty

  • Forecaster
  • *****
  • Posts: 2432
  • Stillwater, home of Oklahoma State University
    • Welcome to Stillwater Weather
Re: wxflyer.php help
« Reply #12 on: January 24, 2013, 10:23:19 PM »
Using notepad create a blank file and when saving the file, name it

nws-forecast-discussion.txt

Then upload it to your site and change the file permissions to 666.

Sorry, but the forecast discussion isn't working on your flyer, either.  As I stated before other people have this problem.

Also the 2nd home page using modified AltDashboard 6.95 at http://stillwaterweather.com/2ndhome.php

Offline Bunty

  • Forecaster
  • *****
  • Posts: 2432
  • Stillwater, home of Oklahoma State University
    • Welcome to Stillwater Weather
Re: wxflyer.php help
« Reply #13 on: January 24, 2013, 10:25:17 PM »
Are you sure you have the .txt file on your site? I cant see it here.. http://hayskansasweather.com/nws-forecast-discussion.txt

Here's what mine looks like... http://www.northbendweather.com/nws-forecast-discussion.txt

Congratulations, the forecast discussion part of your flyer works!

Also the 2nd home page using modified AltDashboard 6.95 at http://stillwaterweather.com/2ndhome.php

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1152
Re: wxflyer.php help
« Reply #14 on: January 25, 2013, 01:35:53 AM »
Using notepad create a blank file and when saving the file, name it

nws-forecast-discussion.txt

Then upload it to your site and change the file permissions to 666.

Sorry, but the forecast discussion isn't working on your flyer, either.  As I stated before other people have this problem.
Yes - I Know. My flyer is modified and does not include the forecast discussion on purpose so the flyer does not get too long and stays on one page. ;)  The line
Code: [Select]
<?php
// make a short paragraph of the forecast discussion
$Status $curl_debug '';
echo 
get_forecast_discussion_flyer();
?>
has been deleted and instead there are 2 more forecasts. The nws-forecast-discussion.txt from 2010 still exists because it is not in use.

I have found that sometimes the scripts don't create the needed txt files the first time, but when one is manually created, the script starts working and overwriting on it. This may or may not work for you, but it doesn't hurt to try. I see that you also have your files in a subfolder of your main directly /wx/. Have you checked for a path issue?
« Last Edit: January 25, 2013, 01:37:37 AM by Dr Obbins »