jdubwelch Posted August 28, 2009 Share Posted August 28, 2009 I'm working on a project that is going to be on a bigger scale than I've ever done. I'm going to have about 65+ different pages all with the same template (or look), with different color schemes & content. Each page will run the same script, but display different content that is being queried from a MySQL Database based on an id. There will be a lot of content on the page that is coming from the DB. My question is... since they're all the same basic "template" do I just have that one file and read in the id to make them different. (ie... 1 file for 65 pages like index.php?id=45) OR set up a whole folder structure for each 65 pages. which would be something like this: NCAA index.php PAC-10 index.php OREGON-DUCKS index.php OREGON-STATE-BEAVERS index.php (times 8 more teams) SEC index.php FLORIDA-GATORS index.php LSU-TIGERS index.php (times 10 other teams) (times 12 other conferences) index.php in the example above would be the same except it's reading a different id. I know the folder structure would be overkill, but say each of the 65 pages are being looked at at the same time. Wouldn't that slow the scripts and page load down? Quote Link to comment https://forums.phpfreaks.com/topic/172246-many-pages-with-one-template-style-best-layout/ Share on other sites More sharing options...
rhodesa Posted August 28, 2009 Share Posted August 28, 2009 By having separate pages, you do have a speed increase, since there wouldn't be any scripts running...but you can solve that with some proper caching mechanisms. The advantage of using templates is that if you want to make a change to something on the template (aka something that is on every page) you only have to change it in one place...and with 65 pages, that will save you HOURS of sanity. I would look into a pre-existing CMS system. A lot of people use Joomla and Drupal...I personally prefer cmsMadeSimple. All of them should allow you to have a template (or even a couple different ones) Quote Link to comment https://forums.phpfreaks.com/topic/172246-many-pages-with-one-template-style-best-layout/#findComment-908335 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.