Display Button list

Size:
Size 16
Size 32



{FILE}'; $count = 0; $mod = 6; $files = array(); $dir = dirname( __FILE__ ) . '/img/b' . $size; $dh = dir( $dir ) ; while( false !== ( $entry = $dh->read() ) ) { if( $entry[0] == '.' ) { continue; } array_push( $files, $entry ); } natsort( $files ); foreach( $files as $file ) { $info = @getimagesize( $dir . '/' . $file ); if( !$info ) { continue; } ++$count; $img = array( '{SRC}' => 'img/b' . $size . '/' . $file, '{WIDTH}' => $info[0], '{HEIGHT}' => $info[1], '{FILE}' => $file ); $html = strtr( $tmpl, $img ); echo $html . "\n"; if( !( $count % $mod ) ) { echo "\n\n"; } } $count = $mod - ( $count % $mod ); for( $i = 0; $i < $count; ++$i ) { echo ''; } ?>