Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Include Files...
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Include Files...

 Post Reply Post Reply
Author
MrCarl View Drop Down
Newbie
Newbie


Joined: 29 March 2003
Status: Offline
Points: 29
Post Options Post Options   Thanks (0) Thanks(0)   Quote MrCarl Quote  Post ReplyReply Direct Link To This Post Topic: Include Files...
    Posted: 23 January 2004 at 5:38am

Just wondering where people draw the line on modulising include files, what I mean by this is do you feel its better to have one large include file on all pages (so sometimes some functions etc in the include file are not used) or do you seperate them into smaller ones, where occasionally some pages may be calling for 5-6 include files??

Basically I wanted to know if its bad practice to be calling 5-6 or more smaller include files on a page?? Is this gonna be slowing things down a lot??

- Carl S

Back to Top
michael View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 April 2002
Location: United States
Status: Offline
Points: 4670
Post Options Post Options   Thanks (0) Thanks(0)   Quote michael Quote  Post ReplyReply Direct Link To This Post Posted: 23 January 2004 at 9:42am
Correct me if I am wrong but I think you have better performance including on larger file then 5 small files. Modulisation ok but keep logic, place your main functions in an include, all you custom data functions in one but not every single function into it's include file.
Back to Top
KCWebMonkey View Drop Down
Senior Member
Senior Member
Avatar
Go Chiefs!

Joined: 21 June 2002
Status: Offline
Points: 1319
Post Options Post Options   Thanks (0) Thanks(0)   Quote KCWebMonkey Quote  Post ReplyReply Direct Link To This Post Posted: 23 January 2004 at 10:32am

I designed an intranet site that utilizes about 10 include files per page, and i see virtually no decrease in performance.

The server has to run through the page at runtime anyways, and it really doesn't slow it down to pull a few more include files...

Back to Top
dpyers View Drop Down
Senior Member
Senior Member


Joined: 12 May 2003
Status: Offline
Points: 3937
Post Options Post Options   Thanks (0) Thanks(0)   Quote dpyers Quote  Post ReplyReply Direct Link To This Post Posted: 23 January 2004 at 7:45pm

I think you have to decide if you want to optimize your includes for performance, or for maintainability. If you have 2 or 3 includes that are used together 90% of the time, you'll save a couple of I/O's by budling them into one include, but increase memory utilization on the 10% of pages where they're not used together.

Personally, I prefer organizing the includes for maintainability - e.g. all the I/O in one include, etc.


Lead me not into temptation... I know the short cut, follow me.
Back to Top
ljamal View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 16 April 2003
Status: Offline
Points: 888
Post Options Post Options   Thanks (0) Thanks(0)   Quote ljamal Quote  Post ReplyReply Direct Link To This Post Posted: 23 January 2004 at 8:57pm
I place them into one include and I break them down after I have finished a project. Most times, I find that there are some that are only used on a single page or a group of page and that most are used on a lot of pages.
Back to Top
Bluefrog View Drop Down
Senior Member
Senior Member


Joined: 23 October 2002
Location: Korea, South
Status: Offline
Points: 1701
Post Options Post Options   Thanks (0) Thanks(0)   Quote Bluefrog Quote  Post ReplyReply Direct Link To This Post Posted: 23 January 2004 at 10:59pm

If you look at it from a cost perspective, on very large busy sites, it might be better to only include what you need, but for small to medium sized sites, human resources are more expensive, so maintainability is the largest cost factor.

MS has a stress testing tool that you can use, but probably a good rule of thumb is that you don't need to worry about it until the site requires a dedicated/co-located server.

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.