Php is_executable determines whether a given file name can be executed for an instance,
The php is_executable function is used to determine whether a file can be executed. If the file exists and is executable, TRUE is returned. If an error occurs, FALSE is returned, this article introduces the basic syntax and instance of the is_executable function.
Introduction to php is_executable Functions
The is_executable function is used to determine whether a given file name is executable.
Syntax:
Bool is_executable (string $ filename)
Determines whether a given file name is executable.
Parameters:
The path of the filename file.
Return Value:
If the file exists and is executable, TRUE is returned, and FALSE is returned when an error occurs.
Php is_executable function instance
Use is_executable to determine whether the permissions. php file can be executed. The Code is as follows:
<? Php $ file_name = "permissions. php "; // Only works on Windows with PHP 5.0.0 or laterif (is_executable ($ file_name) {echo (" The file $ file_name is executable. <br/> ");} else {echo (" The file $ file_name is not executable. <br/> ") ;}?>
The above is to sort out the documents for php is_executable to determine whether the given file name can be executed. We will continue to add relevant materials in the future. Thank you for your support for this site!