Posted on November 26th, 2008
1595 views
This simple function will check if a file exists, this could be good to use when you have to include a config file.
<? In this example i have check if the config file doesnt exist but to check if it does exist then just remove the ! This checks if the file exists, if the file doesnt exist then it will stop executing and display the error message. Although if it does exist then it will carry on and include the file. |