Webcam picture - Forum | JoomShaper
Solved SP Page Builder

Webcam picture

Asked by Gräzer Björn 2 years ago Last activity 2 years ago

Hello

I get every 5min a new picture loaded into following folder: images/webcam. In SP Page Builder I'm puplishing the pucture with the standard image addon.
What do I need to do, that the latest picture is getting loaded. I always just have one picture in the mentioned folder, but the picture is not getting updated in the front end, unless I clear the browser cache.

https://flugplatz-schaenis.ch/piloten

Any solution would be very appriciated.

Accepted answer

Marked as the solution
Paul Frankowski Senior Staff
2 years ago · edited

Hi,

Image addon display only image from selected URL. But it load file ones, it keep that same image. That same would be if you would add image inside Article or Custom Module.

I guess, you need Custom Code Script that will refresh/reload - please talk with php/js developer from your city.


In theory you can reload whole page using a one line of HTML, but it doesn't make sense in your case.

Gräzer Björn Asked this

Thank you very much for the various inputs. In the end, I solved it using the .htaccess file, which works perfectly.

<Files "webcam_picture.jpg"> Header set Cache-Control "no-cache, no-store, must-revalidate" Header set Pragma "no-cache" Header set Expires "0" </Files>

1 more reply

Ofi Khan Staff

Hello Gräzer Björn

Turn off caching in Global Configuration settings and disable your server-side caching. Then check your issue.

Best regards

Gräzer Björn Asked this

Thank you Khan,

This was already set, but still not refreshing the picture. Anyway with the .htaccess update, it works perfectly.

Thanks and best regards
Bjoern

Log in to reply.