Location: PHPKode > projects > INTELIMEN - WYSIWYG HTML Browser Editor > editor/pg.image.list.php
<?include(dirname($SCRIPT_FILENAME)."/lib.editor.inc.php");
$handle=opendir($upload_abs);
while ($entry = readdir ($handle)){
  switch (filetype($upload_abs.$entry)) {
    case 'dir':
      if($entry=='..'){
        $up=explode('/',$path);
        array_pop($up);
        $up=implode('/',$up);
        $dir.="<TR><TD class='dlg'><A class='dlg' href='$PHP_SELF?path=$up'><img src='icon.folder.gif' border='0' align='absmiddle'>&nbsp; $entry</a></TD></TR>\n";
      }
      elseif($entry!='.') $dir.="<TR><TD class='dlg'><A class='dlg' href='$PHP_SELF?path={$path}/$entry'><img src='icon.folder.gif' border='0' align='absmiddle'>&nbsp; $entry</a></TD></TR>\n";
    break;
    case 'file':
      $files[$entry].="<TR><TD class='dlg' nowrap><A class='dlg' href=\"javascript:select_image('".rawurlencode($upload_url.$entry)."')\"><img src=\"icon.picture.gif\" border=\"0\" align=\"absmiddle\">&nbsp; $entry</a></TD></TR>\n";
    break;
  }
}
if (is_array($files)){
ksort($files);
foreach($files as $key => $value)$dir.=$value;
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
  <link rel='stylesheet'  type='text/css' href='styles.editor.inc.css'>
  <script language="javascript">
    function select_image(img_name) {
      parent.ipreview.location = img_name;
    }
  </script>
</head>
<body topmargin="0" leftmargin="0" style="border: 0; margin: 0;" scroll="yes"">
  <table class="dlg" cellpadding="0" cellspacing="0" width="100%" height="1%">
    <?echo $dir;?>
  </table>
</body>
</html>
Return current item: INTELIMEN - WYSIWYG HTML Browser Editor