Possibility to show HTML/PHP as a tile
Closed this issue · 8 comments
Is it possible to point directly at an HTML or PHP page such as HamClock or WeeWX to get real time data on the dashboard?
This is already in the To Do list, along with the separate rotate timer for each tile (now all tiles rotate every 30 s)
Just a note for reference as others may see similar. I'm NOT expecting a 'fix'...!!!!
The National Weather Service has a PHP program that generates a forecast graphic for a given location such as: https://forecast.weather.gov/MapClick.php?lat=28.3874&lon=-80.6048&unit=0&lg=english&FcstType=graphical
A 'right click' on the image and copying its address is similar to: https://forecast.weather.gov/meteograms/Plotter.php?lat=28.3893&lon=-80.6088&wfo=MLB&zcode=FLZ447&gset=18&gdiff=3&unit=0&tinfo=EY6&ahour=0&pcmd=1111111111&lg=en&indu=1!1!1!&dd=3&bw=0&hrspan=48
(Note: I modified the URL to display specific parameters and interval...) The graphic can be displayed in a tile but it does not update using the July 6 HTML file. This was not noted in the past since the entire page was refreshed every 5 minutes but removed with the enhancement of setting refresh/rotate intervals for each tile.
As a work around, I added the meta refresh tag to the HTML file to update every 30 minutes.
Steve - N5NG
Hi Steve,
I've also noticed minor issues like this after removing the refresh meta tag and the javascript page refresh.For example, my Hamclock image hasn't been updated since 50 minutes ago.
The caching prevention mechanism I put in place consists in adding a random string added at the end of the URL as a parameter. It works very well with the majority of the image sources, however, it fails for these sources like you mentioned in your previous email that already have a bunch of parameters already on the URL. I'm trapping this issue in the code and removing the variable I added and trying again to load the image. This works but the image sometimes doesn't get refreshed unless the entire page is reloaded. This is why I was a little bit skeptical about removing the whole page refresh.
Now going back to the topic of the issue of this thread. Yesterday spent few hours working on a new code to load mini-websites on the tiles like in iFrames tags. I haven't finished yet this this experiment. More to come.
Pablo - VA3HDL
Not at all. On the contrary I feel I made a contribution to the community for the ones that found a valuable addition to their shacks. I received very good feedback from many and that keeps me going.
Thanks for your help.
Hmmmm....... The graphical weather PHP image mentioned above is not refreshing with, "" in the HTML. Go big deal..
I believe because the time on the chart is embedded on the links you used...
> https://forecast.weather.gov/meteograms/Plotter.php?lat=28.3874&lon=-80.6048&wfo=MLB&zcode=FLZ747&gset=18&gdiff=3&unit=0&tinfo=**EY5**&ahour=0&pcmd=11101111110000000000000000000000000000000000000000000000000&lg=en&indu=1!1!1!&dd=&bw=&hrspan=48&pqpfhr=6&psnwhr=6
> https://forecast.weather.gov/meteograms/Plotter.php?lat=28.3893&lon=-80.6088&wfo=MLB&zcode=FLZ447&gset=18&gdiff=3&unit=0&tinfo=**EY6**&ahour=0&pcmd=1111111111&lg=en&indu=1!1!1!&dd=3&bw=0&hrspan=48
> https://forecast.weather.gov/meteograms/Plotter.php?lat=28.3893&lon=-80.6088&wfo=MLB&zcode=FLZ447&gset=18&gdiff=3&unit=0&tinfo=**EY7**&ahour=0&pcmd=1111111111&lg=en&indu=1!1!1!&dd=3&bw=0&hrspan=48
the part in between ** and ** is the hour of the chart I believe.
Then wait until the top of the hour and refresh. The X axis time-line changes by one hour where the first labeled hour is the next hour. I don't recall what values I had to change so it shows the 'next' hour labeled minus two hours. The 'hrspan' is the number of hours to display.