i have this php code who auto thumb and arrange my photos to gallery:
<?php
$folder = "../albums/1000/";
$folder3 = "albums/1000/";
$handle = opendir($folder);
$noeffect = "noeffect";
while (false !== ($file = readdir($handle))) {
if (strpos($file, '.png',1)||strpos($file, '.jpg',1)||strpos($file, '.JPG',1) ) {
$imgsrc= "../thumbnail.php?file=";
$imgend= "&width=120&height=120";
echo ("
<li><a href=\"".$folder.$file."\" rel=\"".$rel.external."\" class=\"".$noeffect."\">
<img src=\"".$imgsrc.$folder3.$file.$imgend."\" /></a></li> "); }}
?>
it works great and i love it! but when i upload 200-300 pictures it need to load the thumbs before it could view the big picture in the gallery.. and i thought how can i make load more button or load more on scroll to load like 30 pictures a time..
i search the net and tried many but most of them use mysql and i dont know how to deal it and others were problematic.. any solution? thanks!
You can take a look here for example for what im doing : http://m.eladhamemagnet.net/albums/996.php
btw its for iphone so thats why i need it to load fast
I did pre loading for every picture and it worked..