Fórum
Image Portlet DIsplay all images in a folder using php
Shail Rajput, modificado 11 Anos atrás.
Image Portlet DIsplay all images in a folder using php
New Member Postagens: 12 Data de Entrada: 26/12/12 Postagens Recentes
I have developed a portlet in php which will take all type of image in a folder and display it. I have installed this in my liferay but now i have a problem.
I need to dispaly all image which will be uploaded via image portlet so can any one tell me what sholud i do...
I dont want image gallery to b used.
so plz give me suggestion
so i want this to work for all images being uploaded....
I need to dispaly all image which will be uploaded via image portlet so can any one tell me what sholud i do...
I dont want image gallery to b used.
so plz give me suggestion
<!--?php
// Find all files in that folder
$files = glob('Images/*');
// Do a natural case insensitive sort, usually 1.jpg and 10.jpg would come next to each other with a regular sort
natcasesort($files);
// Display images
foreach($files as $file) {
echo '<img src="' . $file . '" /-->';
}
// ???
// Profit :D
?>
so i want this to work for all images being uploaded....