read()) !== false) { $upper = ucwords($file); if(is_dir($mydir->path.$file) == true && $file != '.' && $file != '..') { $files[] = $file; } } $mydir->close(); $runningtotal = 0; foreach ($files as $file) { $upper = ucwords($file); if ($runningtotal < ((count($files) + 1) / 2)) { $col1 .= "
  • $upper
  • "; } else { $col1 .= "
  • $upper
  • "; } $runningtotal++; } echo "
    "; echo "

    Col 1

    "; echo $col1; echo "
    "; echo "
    "; echo "

    Col 2

    "; echo $col2; echo "
    "; ?>