Invalid gallery.

"; break; } for ($i=1; $i <= 9; $i++) // clear string array $p[$i] = ""; $num=0; // count number of thumbnails $dir = dirname(__FILE__) . '/' . $d; if (is_dir($dir)) { if ($dh = opendir($dir)) { while (($file=readdir($dh)) !== false) { if (filetype($dir . $file) === 'file') { if (strncmp($file, "thumb", 5) == 0) { $idx = sprintf("%1d", substr($file, 6, 1)); if (($idx >= 1) && ($idx <= 9)) { $num++; $p[$idx]="$idx"; } } } } } else echo "Directory did not open.
"; } else echo "Not a directory.
"; if ($num > 9) $num = 9; // maximum of 9 thumbnails. ?>

   
";} else echo " ";?> ";} else echo " ";?> ";} else echo " ";?> ";?>
";} else echo " ";?> ";} else echo " ";?> ";} else echo " ";?>
";} else echo " ";?> ";} else echo " ";?> ";} else echo " ";?>