當前位置: 首頁> 函數類別大全> file_exists

file_exists

檢查文件或目錄是否存在
名稱:file_exists
分類:文件系統
所屬語言:php
一句話介紹:檢查文件或目錄是否存在。

實例

<span class="token php language-php"><span class="token delimiter important"><?php</span>
<span class="token keyword">echo</span> <span class="token function">file_exists</span> <span class="token punctuation">(</span> <span class="token string double-quoted-string">"test.txt"</span> <span class="token punctuation">)</span> <span class="token punctuation">;</span>
<span class="token delimiter important">?></span></span>

輸出:

 1
同類函數
  • 返回文件指針讀/寫的位置 ftell

    ftell

    返回文件指針讀/寫的位置
  • 取得文件的inode 修改時間 filectime

    filectime

    取得文件的inode修改時間
  • 輕便的諮詢文件鎖定 flock

    flock

    輕便的諮詢文件鎖定
  • 倒回文件指針的位置 rewind

    rewind

    倒回文件指針的位置
  • 刪除文件 unlink

    unlink

    刪除文件
  • 設定文件的訪問和修改時間 touch

    touch

    設定文件的訪問和修改時間
  • 判斷文件是否是通過HTTP POST 上傳的 is_uploaded_file

    is_uploaded_file

    判斷文件是否是通過HTTPPOST上傳的
  • 提供有關文件的信息 stat

    stat

    提供有關文件的信息