25-03-2017, 14:29
Since the website is running fine I'd like to add a weather camera to the website, problem is I have no idea how websites are put together or how it works.
Managed to add a "webcam" page and display an image from copying code from here:http://sandaysoft.com/forum/viewtopic.php?f=19&t=15807
All seems to work fine, but the latest image is not loaded.
I do understand why the latest image is not loaded as the filename of the image to display is hardcoded and I need some code to load the latest image the webcam ftp'd to the webserver.
The webcam upload the images via ftp to the webserver as "cam1_20170325-150650.jpg" for example, problem is the date and time stamp within the filename changes as the webcam uploads new images.
How do I load the latest image with the filename constantly changing?
Anyone that can assist?
My webcam page: http://mht.co.za/weather/webcams.htm
Managed to add a "webcam" page and display an image from copying code from here:http://sandaysoft.com/forum/viewtopic.php?f=19&t=15807
All seems to work fine, but the latest image is not loaded.
I do understand why the latest image is not loaded as the filename of the image to display is hardcoded and I need some code to load the latest image the webcam ftp'd to the webserver.
The webcam upload the images via ftp to the webserver as "cam1_20170325-150650.jpg" for example, problem is the date and time stamp within the filename changes as the webcam uploads new images.
How do I load the latest image with the filename constantly changing?
Anyone that can assist?
My webcam page: http://mht.co.za/weather/webcams.htm

