I'm looking for this to work with video but it could equally work with photos and other multimedia. I'm wanting to create a page with various sections each held in their own div. I then will have a folder where I will upload a still from the video, the video itself and the title and description in different files. I then want each div to go into this folder and select the last uploaded files and display them. You will then be able to click on the div and it will open up another page with the title, description and video. I have been searching around but think that my request is too specific to try and find an answer. I'm guessing that I will need to use php somewhere along the way such as selecting the folder and getting the last uploaded files but am unsure what else and even how to build everything else. I'd be grateful of any information you could give.
问问题
83 次
1 回答
0
这是一种按修改时间列出图库中图像的简单方法:
$images = glob("gallery/*.jpeg");
$images = array_combine($images, $images);
$images = array_map("filemtime", $images);
arsort($images);
print_r(array_keys($images));
尽管您需要更多代码来漂亮地打印它。
如果您实际上正在寻找代码或一些现成的脚本,那么我认为有“PHP Gallery” 。
于 2011-02-13T01:31:10.643 回答