If you have 200 include files containing one function each then it will take
longer to load that one include file containing all 200 functions. I
personally group similar functions into the same include file, but have each
database table class in its own file. At runtime I only load the files that
I know I will need. I can also have different versions of functions in
different files, so I can load include.xml.php4.inc or include.xml.php5.inc
depending on which version of PHP I am running.
It takes a little up-front organisation, but I think it's worth it.
--
Tony Marston
http://www.tonymarston.net
"Tom Cat" <stry_cat@yahoo.com> wrote in message
news:fa408b52.0409161031.69c842ad@posting.google.c om...[color=blue]
> Is there anything wrong with using a lot of include files?
>
> On one part of my website, I have a form. The page it posts data to,
> includes a different file based on some of the values. The include
> files also include other pages based on different values. All of
> these work together to select the right information from the database
> and display it in the correct format.
>
> I'm just wondering if it is better to put all the code in one file
> rather than in the include files.
>
> Thanks,
>
> -Tom[/color]