renfley Posted December 4, 2010 Share Posted December 4, 2010 Hey guys havent coded in a while and im stumped. Ive checked google but to no avail lol i wanna include my config file and have an IF statement to run/include another file IE... <?php include("config/config.php"); If File(Not Exist); include("install/config.php"); ?> If someone can put me back on track it would be greatly epreciated Link to comment https://forums.phpfreaks.com/topic/220663-hell-of-a-newb-question/ Share on other sites More sharing options...
Rifts Posted December 4, 2010 Share Posted December 4, 2010 <?php $filename = '/path/to/foo.txt'; if (file_exists($filename)) { echo "The file $filename exists"; } else { echo "The file $filename does not exist"; } ?> Link to comment https://forums.phpfreaks.com/topic/220663-hell-of-a-newb-question/#findComment-1142939 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.