runkit_lint_file

(PECL)

runkit_lint_file --  Check the PHP syntax of the specified file

說明

bool runkit_lint_file ( string filename )

The runkit_lint_file() function performs a syntax (lint) check on the specified filename testing for scripting errors. This is similar to using php -l from the commandline.

注: 對沙盒的支援(是函數 runkit_lint()runkit_lint_file() 和 Runkit_Sandbox 類所必須的)僅在 PHP 5.1 中,或在加過特別修改更新的 PHP 5.0 中,並需要啟用執行緒安全。請閱讀 runkit 包中的 README 檔案以瞭解更多訊息。

參數

filename

File containing PHP Code to be lint checked

返回值

若果成功則返回 TRUE,失敗則返回 FALSE