Hi,
I'm new to PHP, but I'm loving its use so far. I have two pretty
boring questions I can't seem to find the answer to:
I have a template-driven site which uses PHP to drop in menu,
content, etc. Most of the content is pure HTML, but there are
a couple of special cases. To simplify my code, I'd like to
change the extensions for all of my files from .html to .php.
My question is this: will doing this slow my site down? Because
then these files must be run through the PHP parser, even though
there's nothing to parse.
My second question is also pretty easy: when I do a require(), does
that essentially copy and paste the require()'d file into the file
which require()'d it? Basically, will I lose performance if I
require() a .php file versus a .html file, assuming they are both
pure HTML content?
Thanks in advance,
Sanford Armstrong
I'm new to PHP, but I'm loving its use so far. I have two pretty
boring questions I can't seem to find the answer to:
I have a template-driven site which uses PHP to drop in menu,
content, etc. Most of the content is pure HTML, but there are
a couple of special cases. To simplify my code, I'd like to
change the extensions for all of my files from .html to .php.
My question is this: will doing this slow my site down? Because
then these files must be run through the PHP parser, even though
there's nothing to parse.
My second question is also pretty easy: when I do a require(), does
that essentially copy and paste the require()'d file into the file
which require()'d it? Basically, will I lose performance if I
require() a .php file versus a .html file, assuming they are both
pure HTML content?
Thanks in advance,
Sanford Armstrong
Comment