<style>
#show img{
max-height:400px;
}
</style>
[removed][removed]
<?php
echo '[removed]pic = new Array(); var num = 0;';
$i = 0;
$dir = "./images/";
if( is_dir($dir) )
if( $dh = opendir($dir) )
while( ($file = readdir($dh)) !== false )
if( !($file == '.' || $file == '..') ){
$fi = getimagesize($dir.$file);
if($fi['2']=='1' || $fi['2']=='2' || $fi['2']=='3' || $fi['2']=='4') echo 'pic[',$i++,']="'.$dir.$file.'";';
}
echo 'total = ',$i,';[removed]';
?>
<div id="show">
<img src="" id="img" >
</div>
[removed]
$("#img").fadeIn(function(){
$(this).attr("src",pic[0]);
});
function dothat(gpoint){
(gpoint == 'b') ? num = num-1 : num = num+1;
if(num == -1 || num < -1) num = total -1 ;
num = num % total;
$('#img').fadeOut(function(){
$(this).attr("src",pic[num]);
$(this).fadeIn();
});
}
function hupdiye(a){
alert(a + ' suanki resim id numarasi');
}
[removed]
<a href="[removed]dothat('b');">Back</a> - <a href="[removed]dothat();">Next</a><br><br>Add a code snippet to your website: www.paste.org