I\'d like to display the last modified image in a directory that ends in a specific way.
I have it working to display the last file in the directory I only don\'t know h
That is my way, resolving this issue, I am not a programmer, it is try on error product :)
I used it in a wordpress installation and had to install the plugin Allow PHP in Posts and Pages (thats why the php tags are different, normally instead of [PHP] [/PHP])
[PHP]
global $path; // path to directory has to be global, using it later in html
$dir = "Planetwebcam/";
$files = scandir($dir, 1); // read directory backkwards
$picture = ($files[0]); // get las picture file name
$path = "http://www.yourdomain.ch/Planetwebcam/$picture";
[/PHP]