Author Topic: wxhistory.php  (Read 572 times)

0 Members and 1 Guest are viewing this topic.

Offline meteosanjuan

  • Senior Member
  • **
  • Posts: 75
    • Meteosanjuan
wxhistory.php
« on: April 17, 2024, 01:26:50 PM »
In order to make some order in the root folder where the website is stored, I decided to move the graphs generated by weather display in the Daily Report for the month (wxhistory.php)

So create a folder “daily graphics” and after moving the gifs change the path to
$wxh_graphs_path = './daily_graphs/';

Since the graph was too big, I added the width and height="600" clauses, which I really don't know if it's recommended.

And the result is that it works, however I can't figure out where to indicate that the gifs that weather display uploads do so to the folder I want, it uploads them to the root.
Can anyone tell me how to do it?

The site is https://www.meteosanjuan.com/wxhistory.php

Thank you

Offline Weerstation

  • Member
  • *
  • Posts: 45
    • Westland De Poel
Re: wxhistory.php
« Reply #1 on: April 20, 2024, 04:06:01 AM »
Hi,
Have you looked at.

Control Panel
FTP Connections Metar NOAA
[Tab] Webfiles Upload Times and Av/Ext
See Extra Options

Offline meteosanjuan

  • Senior Member
  • **
  • Posts: 75
    • Meteosanjuan
Re: wxhistory.php
« Reply #2 on: April 24, 2024, 07:13:33 AM »
That's how it is. Thank you very much for pointing it out to me. Greetings

Offline meteosanjuan

  • Senior Member
  • **
  • Posts: 75
    • Meteosanjuan
Re: wxhistory.php
« Reply #3 on: May 01, 2024, 06:06:42 AM »
I finally managed to fix this report and put some order in the root directory of my web hosting, however, there are two reports that have stopped working for me, I understand that the path is not well indicated in the script.

The first https://www.meteosanjuan.com/wxnoaaclimatereports.php I have modified without success

$NOAAdir = isset($SITE['NOAAdir'])?$SITE['NOAAdir']:'./dailyreports/';
$NOAACurDir = isset($SITE['NOAACurDir'])?$SITE['NOAACurDir']:'./dailyreports/';

In the second in the annual reports https://www.meteosanjuan.com/wxtempdetail.php I can't find where I should change the route.

The idea is that the root of the server is not so loaded with files, which when trying to search for a specific one is an expensive mission, since the website has been running since 2010

Can anybody help me?

Offline hcorrin

  • Contributor
  • ***
  • Posts: 145
    • Ballaugh Weather
Re: wxhistory.php
« Reply #4 on: May 01, 2024, 12:13:43 PM »
For your second query try the wxreport-settings.php lines 29-30
For the first try include-NOAA-reports.php lines 71-72
« Last Edit: May 01, 2024, 12:17:21 PM by hcorrin »

Offline meteosanjuan

  • Senior Member
  • **
  • Posts: 75
    • Meteosanjuan
Re: wxhistory.php
« Reply #5 on: May 01, 2024, 01:36:55 PM »
Well, thank you very much, by changing the path as indicated and copying the dailynoareport folder to the folder, I have been able to fix the second one, that is, the one with the monthly report.

However, the first one resists me, even having indicated the path in the lines of the include-NOAA-reports.php script as you indicate.

https://www.meteosanjuan.com/wxnoaaclimatereports.php

It generates the following error:

Warning: File (./dailynoaareport52024.htm): Failed to open stream: No such file or directory in /home/meteosan/www/include-NOAA-reports.php on line 364

And I don't understand it because this file is located in the path indicated in the script:

$NOAAdir = isset($SITE['NOAAdir'])?$SITE['NOAAdir']:'./dailyreports/';
$NOAACurDir = isset($SITE['NOAACurDir'])?$SITE['NOAACurDir']:'./dailyreports/';

Any ideas?

Thank you
« Last Edit: May 01, 2024, 03:09:56 PM by meteosanjuan »

Offline hcorrin

  • Contributor
  • ***
  • Posts: 145
    • Ballaugh Weather
Re: wxhistory.php
« Reply #6 on: May 01, 2024, 07:23:00 PM »
Try '../dailyreports/'; ie two . Instead of one
« Last Edit: May 01, 2024, 07:25:31 PM by hcorrin »

Offline meteosanjuan

  • Senior Member
  • **
  • Posts: 75
    • Meteosanjuan
Re: wxhistory.php
« Reply #7 on: May 02, 2024, 12:52:59 PM »
Well no, there is no way, it is as if this instruction does not exist, keep looking at the root

$NOAAdir = isset($SITE['NOAAdir'])?$SITE['NOAAdir']:'../dailyreports/';
$NOAACurDir = isset($SITE['NOAACurDir'])?$SITE['NOAACurDir']:'../dailyreports/';

Let's see if Ken comes by and enlightens me

Thanks for your help

Offline hcorrin

  • Contributor
  • ***
  • Posts: 145
    • Ballaugh Weather
Re: wxhistory.php
« Reply #8 on: May 02, 2024, 05:47:08 PM »
check line 47 in the settings-weather.php and revert ../dailyreports/ to ./ in the include

Offline meteosanjuan

  • Senior Member
  • **
  • Posts: 75
    • Meteosanjuan
Re: wxhistory.php
« Reply #9 on: May 02, 2024, 06:16:02 PM »
Yes sir, this is the line of code that contains the path of the dailynoaareports file. Those contained in the include in my case are not decisive. Now it works correctly.

check line 47 in the settings-weather.php and revert ../dailyreports/ to ./ in the include

Thank you very much and sincerely for your invaluable help. And although there is room for improvement, I still have some graphics and report files to relocate, the root of the server is much cleaner.

Greetings