From: "Ben Smith" <ben@b...>
Subject: [proasp_howto] Best Practices
: I was wondering, in terms of coding best practices and
: in terms of the fastest approach, is it best to keep all one's
: repeated code in a common.asp or to keep it in various
: includes and include them when required.
: I realise that the common.asp could get quite big and
: not every part would get used but I was also unsure
: about including something like 7 includes!
Only 7 includes? <grin>
All the included code is in routines right? (subs and functions?). I'd group
them by type, and include only those files required. Including a dozen files
isn't a problem - layout though is key, so your page doesn't become a mess:
<% @Declarations here%>
<% Option Explicit %>
<!-- #include files here -->
ASP event driven code here
Also, I can not say how strongly I agree with Aaron - includes that include
more includes are a sign of bad code organisation in my books...