Jump to content
php.lv forumi

lightbox iespējas un galeriju veidošana


BaLTais

Recommended Posts

  $handle = opendir ('./img');
       while (false !== ($file = readdir($handle))) {
           if($file != "." && $file != ".." && $file != basename(__FILE__)) {
               echo '<a href="img/'.$file.'" rel="lightbox[grupa]" title=""><img src="img/'.$file.'" width="314" height="122"/></a>';
           }        
       }	

Izmantoju lightbox 2.04, lai smuki skatītos galeriju. Viss strādā lieliski.

 

Bet vai ir variant vispār šādu kodu pārveidojot panākt sekojošu rezultātu:

-browserī parādās tikai divas pirmās bildes no visas galerijas, bet uzspiežot uz jebkuras no divām bildēm - atveras javascript logs, kurā rāda šīs divas bildes plus visas pārējās, kas ir norādītajā folderī!

 

 

Paldies

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...