ShoeLace1291 Posted August 6, 2007 Share Posted August 6, 2007 I want to include a certain file that's in a parent folder. For example, the file "config.php" is located in public_html/ and the file i'm including it in is in public_html/admin/ How do I include public_html/config.php in public_html/admin/index.php? Link to comment https://forums.phpfreaks.com/topic/63492-include-file-in-parent-folder/ Share on other sites More sharing options...
sKunKbad Posted August 6, 2007 Share Posted August 6, 2007 you just put a period or two in front of the location you have been trying like this: include('./file.php'); or include('../file.php'); try the single period first. Link to comment https://forums.phpfreaks.com/topic/63492-include-file-in-parent-folder/#findComment-316490 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.