Author Topic: information overflow ajaxgizmo  (Read 826 times)

0 Members and 1 Guest are viewing this topic.

Offline meteosanjuan

  • Contributor
  • ***
  • Posts: 123
    • Meteoensevilla
information overflow ajaxgizmo
« on: January 11, 2025, 07:50:22 AM »
Hello:

Hi, I haven't been able to fix the overflow that occurs when pausing AjaxGizmo when viewing the entire web from a mobile device. I honestly don't know how to fix it.

Thanks if anyone has any tips for me.

https://www.meteoensevilla.es

Offline saratogaWX

  • Administrator
  • Forecaster
  • *****
  • Posts: 9672
  • Saratoga, CA, USA Weather - free PHP scripts
    • Saratoga-Weather.org
Re: information overflow ajaxgizmo
« Reply #1 on: January 11, 2025, 09:04:14 AM »
The 'updates paused' message is controlled by the ajaxWDwx.js setting
Quote
var maxupdates = 50;         // Maxium Number of updates allowed (set to zero for unlimited)
Change that to
Quote
var maxupdates = 0;         // Maxium Number of updates allowed (set to zero for unlimited)
and the AJAX updates will run and never time-out with the 'updates paused' message.
Ken True/Saratoga, CA, USA main site: saratoga-weather.org
Davis VP1+ FARS, Blitzortung RED, GRLevel3, WD, WL, VWS, Cumulus, Meteobridge
Free weather PHP scripts/website templates - update notifications on Twitter saratogaWXPHP

Offline meteosanjuan

  • Contributor
  • ***
  • Posts: 123
    • Meteoensevilla
Re: information overflow ajaxgizmo
« Reply #2 on: January 11, 2025, 02:06:53 PM »
Hi Ken:

Thanks for your reply. I had already thought about what you are saying and in fact I had changed the value of var maxupdates to 50. I didn't want to set it to 0 because I understand that it constantly draws data from the server and I am worried that it could crash due to excess traffic.

Is there no way to fix the mismatch? Because I have the feeling that the font could be smaller.

Thanks

Offline saratogaWX

  • Administrator
  • Forecaster
  • *****
  • Posts: 9672
  • Saratoga, CA, USA Weather - free PHP scripts
    • Saratoga-Weather.org
Re: information overflow ajaxgizmo
« Reply #3 on: January 11, 2025, 03:15:09 PM »
So, two things:

1) setting maxupdates = 0;  in ajaxWDwx.js will only cause your clientraw.txt to be fetched by anyone browsing your page at every 10 seconds based on your setting of
Quote
var reloadTime = 10000;       // reload AJAX conditions every 5 seconds (= 5000 ms)
and server processing for .txt files is negligible.  A PHP page would be much more server intensive than a text file, so I wouldn't worry about that.

2) the font mismatch you cite is likely caused by HTML errors in the page.. do a validation and correct any errata cited, then the font should display as you expect.  With HTML errata, the browser 'tries' to do what it thinks you want, but sometimes gets it wrong -- the only way to ensure perfect presentation is to have perfect HTML for the browser to see.
Ken True/Saratoga, CA, USA main site: saratoga-weather.org
Davis VP1+ FARS, Blitzortung RED, GRLevel3, WD, WL, VWS, Cumulus, Meteobridge
Free weather PHP scripts/website templates - update notifications on Twitter saratogaWXPHP

Offline meteosanjuan

  • Contributor
  • ***
  • Posts: 123
    • Meteoensevilla
Re: information overflow ajaxgizmo
« Reply #4 on: January 11, 2025, 05:02:31 PM »
Following your advice I set the variable var maxupdates to 0

I am not qualified to correct errors in sources.

Thank you as always.

Offline meteosa

  • Member
  • *
  • Posts: 32
Re: information overflow ajaxgizmo
« Reply #5 on: January 12, 2025, 11:21:59 AM »
Hi,
I'm linking to this post to ask you how can I set the months in Italian in ajaxgizmo? Now January puts it "Jan" or set it to "01"
https://www.meteosantangelo.it/dash/gizmotest1.php
Thanks

Offline saratogaWX

  • Administrator
  • Forecaster
  • *****
  • Posts: 9672
  • Saratoga, CA, USA Weather - free PHP scripts
    • Saratoga-Weather.org
Re: information overflow ajaxgizmo
« Reply #6 on: January 12, 2025, 04:31:50 PM »
Hi,
I'm linking to this post to ask you how can I set the months in Italian in ajaxgizmo? Now January puts it "Jan" or set it to "01"
https://www.meteosantangelo.it/dash/gizmotest1.php
Thanks
There is no current translation function to convert 3-character English month name abbreviations into other language 3-character month names.

I suggest you change ajaxWDwx3.js from
Quote
var metricUOM =
   {Temp: '°C' // [ &dec;C | &dec;F ] ..........................Temp
   ,Wind: 'kph'    // [ kts | mph | kph  | m/s  ] ................. Wind
   ,Baro: 'hPa'    // [ hPa | mb  | inHg | mmHg ] ................. Baro
   ,Rain: 'mm'     // [ mm  | in  ] ............................... Rain
   ,Soil: 'cm'     // [ cm  | in  } ............................... Soil Sensor Depth
   ,Moist:'kp'      // [ kp  | cb  ] ............................... Soil Moisture
   ,Snow: 'cm'     // [ cm  | in  ] ............................... Snow
   ,Alti: 'm'      // [ m   | ft  ] ........................... Altitude
   ,Dist: 'km'     // [ m   | km  | miles] .................... Distance
   ,Deg : '°'  // [ deg | ° ] ........................ Direction
   ,dateFmt: "j-M-Y" // 26-04-2009 ... same format as "date" function in php (eg. for DE use "j.M.Y", for NL use "j-M-Y)
   ,timeFmt: "H:i:s" // 15:27:01 ..... same format as "date" function in php  ( for 12h clock use "g:i:s a" )
   ,timeHM : "H:i"   // 15:27 ........ same format as "date" function in php  ( for 12h clock use "g:i a" )
   };
to
Quote
var metricUOM =
   {Temp: '°C' // [ &dec;C | &dec;F ] ..........................Temp
   ,Wind: 'kph'    // [ kts | mph | kph  | m/s  ] ................. Wind
   ,Baro: 'hPa'    // [ hPa | mb  | inHg | mmHg ] ................. Baro
   ,Rain: 'mm'     // [ mm  | in  ] ............................... Rain
   ,Soil: 'cm'     // [ cm  | in  } ............................... Soil Sensor Depth
   ,Moist:'kp'      // [ kp  | cb  ] ............................... Soil Moisture
   ,Snow: 'cm'     // [ cm  | in  ] ............................... Snow
   ,Alti: 'm'      // [ m   | ft  ] ........................... Altitude
   ,Dist: 'km'     // [ m   | km  | miles] .................... Distance
   ,Deg : '°'  // [ deg | ° ] ........................ Direction
   ,dateFmt: "j/m/Y" // 26-04-2009 ... same format as "date" function in php (eg. for DE use "j.M.Y", for NL use "j-M-Y)
   ,timeFmt: "H:i:s" // 15:27:01 ..... same format as "date" function in php  ( for 12h clock use "g:i:s a" )
   ,timeHM : "H:i"   // 15:27 ........ same format as "date" function in php  ( for 12h clock use "g:i a" )
   };

to display the date in numbers only.
Ken True/Saratoga, CA, USA main site: saratoga-weather.org
Davis VP1+ FARS, Blitzortung RED, GRLevel3, WD, WL, VWS, Cumulus, Meteobridge
Free weather PHP scripts/website templates - update notifications on Twitter saratogaWXPHP

Offline meteosa

  • Member
  • *
  • Posts: 32
Re: information overflow ajaxgizmo
« Reply #7 on: January 13, 2025, 05:23:13 AM »
ok, but why is it translated here? Is it something else?
https://www.meteosantangelo.it/dash/wxdashboard.php
thanks

Offline saratogaWX

  • Administrator
  • Forecaster
  • *****
  • Posts: 9672
  • Saratoga, CA, USA Weather - free PHP scripts
    • Saratoga-Weather.org
Re: information overflow ajaxgizmo
« Reply #8 on: January 13, 2025, 10:12:39 AM »
Maybe it is caused by not loading
Quote
<script type="text/javascript" src="language-it.js"></script>
after
Quote
<script type="text/javascript" src="ajaxWDwx3.js"></script>
in your https://www.meteosantangelo.it/dash/gizmotest1.php code.
Ken True/Saratoga, CA, USA main site: saratoga-weather.org
Davis VP1+ FARS, Blitzortung RED, GRLevel3, WD, WL, VWS, Cumulus, Meteobridge
Free weather PHP scripts/website templates - update notifications on Twitter saratogaWXPHP

Offline meteosa

  • Member
  • *
  • Posts: 32
Re: information overflow ajaxgizmo
« Reply #9 on: January 13, 2025, 11:53:41 AM »
so i have to make some code changes? sorry i dont understand.

Offline saratogaWX

  • Administrator
  • Forecaster
  • *****
  • Posts: 9672
  • Saratoga, CA, USA Weather - free PHP scripts
    • Saratoga-Weather.org
Re: information overflow ajaxgizmo
« Reply #10 on: January 13, 2025, 12:18:23 PM »
Yes, in your gizmotest1.php page, change
Quote
<script type="text/javascript" src="ajaxWDwx3.js"></script>
to
Quote
<script type="text/javascript" src="ajaxWDwx3.js"></script>
<script type="text/javascript" src="language-it.js"></script>
Ken True/Saratoga, CA, USA main site: saratoga-weather.org
Davis VP1+ FARS, Blitzortung RED, GRLevel3, WD, WL, VWS, Cumulus, Meteobridge
Free weather PHP scripts/website templates - update notifications on Twitter saratogaWXPHP

Offline meteosa

  • Member
  • *
  • Posts: 32
Re: information overflow ajaxgizmo
« Reply #11 on: January 13, 2025, 12:58:27 PM »
Yes, in your gizmotest1.php page, change
Quote
<script type="text/javascript" src="ajaxWDwx3.js"></script>
to
Quote
<script type="text/javascript" src="ajaxWDwx3.js"></script>
<script type="text/javascript" src="language-it.js"></script>
it works, thanks