Home > Backend Development > PHP Tutorial > 浏览目录_PHP

浏览目录_PHP

WBOY
Release: 2016-06-01 12:30:22
Original
801 people have browsed it



浏览目录



 // 使用表格浏览目录的结构
 print("\n");
 // 创建表格的头
 print("\n");
 print("
\n");
 print("\n");
 print("\n");
 $myDirectory = opendir(".");  // 建立操作目录的句柄
 // 读出目录中的每一个子项
 while($entryName = readdir($myDirectory))
 {
  print("");
  print("");
  print("");
  print("\n");
 }
 closedir($myDirectory);   // 关闭目录
 print("
文件名文件的大小
$entryName");
  print(filesize($entryName));
  print("
\n");
?>


/upimg/php/20070123/11E55139342039629.jpg
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template