JoaoJ Posted July 6, 2012 Share Posted July 6, 2012 Hi, when making a forum, is there any reason why/whynot i should use just 1 single file or why/whynot should i split all the pages/sections/topics in individual files? Thanks for any info on this. Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/ Share on other sites More sharing options...
Barand Posted July 6, 2012 Share Posted July 6, 2012 Lots of small files would make searches a nightmare. Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/#findComment-1359752 Share on other sites More sharing options...
ManiacDan Posted July 6, 2012 Share Posted July 6, 2012 Explain more what you mean by "file"? Do you mean one enormous 10mb PHP file that runs the entire forum? Or are you talking about using files instead of databases? Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/#findComment-1359756 Share on other sites More sharing options...
JoaoJ Posted July 6, 2012 Author Share Posted July 6, 2012 Explain more what you mean by "file"? Do you mean one enormous 10mb PHP file that runs the entire forum? Or are you talking about using files instead of databases? No, no, one file only with the PHP forum, then the DB on the side Actually, like this own forum uses, just one file, named index.php, all actions are by URL. That, agaisnt one file for sections, one for topics, one for posts, one for posting, so on... Although the way i plan it (small forum, not many features) would not get to 10Mb or even close Just wanting to figure out reasons why i could use such a way, or not use that way at all. I'm not very good in the tech side of server/db. Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/#findComment-1359759 Share on other sites More sharing options...
ManiacDan Posted July 6, 2012 Share Posted July 6, 2012 This site is powered by hundreds, if not thousands of files. Index.php, if it exists at all, is a router file which includes the appropriate files for what you're attempting to do. Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/#findComment-1359760 Share on other sites More sharing options...
JoaoJ Posted July 7, 2012 Author Share Posted July 7, 2012 This site is powered by hundreds, if not thousands of files. Index.php, if it exists at all, is a router file which includes the appropriate files for what you're attempting to do. Oh, crap, you are right, didnt noticed it was SMF In any case, i did a "sketch" of the forum, and due to the simplicity i want, it was just one file, and not that big (not that small either ). Just wondering if, server side, was best to use just that one file, or split it in a few. Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/#findComment-1359818 Share on other sites More sharing options...
jcbones Posted July 7, 2012 Share Posted July 7, 2012 Includes take a little overhead, but with the savings you have in de-bugging, or adding without sorting through 1 gigantic file it is worth it. Voting for smaller files. Quote Link to comment https://forums.phpfreaks.com/topic/265330-php-forum-1-huge-file-or-many-small-files/#findComment-1359822 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.