"; if((ereg("(INFO|SECTIONS|.html|.xvpics|htaccess|.desc)", $buffer)) or ($buffer == "tn") or ($buffer == ".") or ($buffer == "..")) {} else { $foo[$i] = $buffer; $i++; } } sort($foo); reset($foo); $img_filename=$image.".jpg"; $self=0; $rdf=0; $small_position=-1; $big_position=-1; $rdf_position=-1; $previous_position=-1; $previous=0; $next_position=-1; $next=0; $self_position=-1; $equiv_number=0; for($j=0; $j<$i; $j++) { $file_scanned = $foo [$j]; // $body=$body.""; $file_basename=eregi_replace("(.jpg|.gif|.jpeg|.png|.rdf|-exif|-small)","",$file_scanned); if($file_basename == $img_basename) { /* we have an equivalent */ $equiv_number++; if ($file_scanned == $img_filename) { $self_position= $j; $self=1; } elseif (ereg(".rdf", $file_scanned)) { $rdf_position= $j; $rdf=1; } } elseif(!($self)) /*not found itself yet, not an equivalent, we're before */ { if (eregi(".jpg",$file_scanned)) { $previous_position = $j; $previous=1; $previous_title = get_title($foo[$previous_position]); } } else /*already found itself, not an equiv,we're after */ { if (eregi(".jpg",$file_scanned)) { $next_position=$j; $next=1; $next_title = get_title($foo[$next_position]); $j = $i; } } } /* end file listing loop */ /* escaped raw html */?> Photo: $title \n"); ?> "; $body=$body."

2 Neurones and  1 Camera

\n"; $body=$body.readrdf_album("$dir/meta.rdf")."\n"; $body=$body. "—

$title

\n"; $body=$body."\n\n"; $body=$body."
\n"; if(!($self)) /* bogus request, dammit! */ { $body=$body."

File not found.

"; } else /* proceed */ { $body=$body."
\n"; $body=$body."\"photo:\n"; $body=$body."
"; if($previous){ $navlink=$navlink."\n";} if($next){ $navlink = $navlink."\n"; } if($rdf) { $body=$body."
"; $body=$body.'

'.readrdf_photo("$dir/$foo[$rdf_position]").'

'; $body=$body."
\n"; } if($previous) { $body=$body."$previous_title\n"; } if($next) { $body=$body."$next_title\n"; } } echo $body; ?>

©/CC 2000- Olivier Thereaux. Some rights reserved.