Revision: 20059
Updated Code
at November 5, 2009 15:54 by garretjames
Updated Code
<?php
if ($handle = opendir('Images/Slideshow')) {
while (false !== ($file = readdir($handle)))
{
if ( preg_match( "/[.]jpg$/", $file ) ) {
preg_match( "/_(\d+)_(\d+)[.]/", $file, $found );
?>
<div class="imageElement">
<h3></h3>
<p></p>
<a href="#" title="open image" class="open"></a>
<img src="Images/Slideshow/<?php echo $file; ?>" class="full" /></div>
<?php
}
}
closedir($handle);
}
?>
Revision: 20058
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at November 5, 2009 15:53 by garretjames
Initial Code
<?php
if ($handle = opendir('Images/Slideshow')) {
while (false !== ($file = readdir($handle)))
{
if ( preg_match( "/[.]jpg$/", $file ) ) {
preg_match( "/_(\d+)_(\d+)[.]/", $file, $found );
?>
<div class="imageElement">
<h3></h3>
<p></p>
<a href="#" title="open image" class="open"></a>
<img src="Images/Slideshow/<?php echo $file; ?>" class="full" /></div>
<?php
}
}
closedir($handle);
}
?>
Initial URL
Initial Description
Initial Title
Image names in directory
Initial Tags
php, directory
Initial Language
PHP