#including a file full of functions. Performance h

Results 1 to 3 of 3

Thread: #including a file full of functions. Performance h

  1. #1
    swordfish Guest

    Default #including a file full of functions. Performance h

    I have an asp file that contains about 30 functions that my application uses. I am including the function file on virtually every page.<BR><BR>Most of the pages that include the function file only require 1 or 2 of the functions.<BR><BR>My question is: since include files are inserted into the document prior to execution, does this greatly impact performance and load time? Can this file be cached? Im concerned about loading the entire file into every document even though the document may only use 20-30 lines of the 1500 line file.<BR><BR>If this is bad practice, what would be a better approach???

  2. #2
    Join Date
    Dec 1969

    Default sure

    just use the functions you need on each page, or write them in VB and compile them in a DLL.

  3. #3
    Join Date
    Dec 1969

    Default further info

    there&#039;s a discussion on this at http://www.infinitemonkeys.ws/ - entitled "coding approaches : processpage vs Modular"<BR><BR>I frown heavily on these massive include files, especially since a firm i USED to work for insisted on encapsulating the entire site in one big include (like 2500 lines of barely optimised VBScript) (including all administration functions - how pointless?) - I could sit there on VNC looking at the server hitting 100% CPU when pages were requested, and no-one even considered changing their methodology. I left.<BR><BR>j<BR>http://www.atrax.ws/<BR><BR>j

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts