Re: include statement

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



So just so I'm clear on your files...

Let's say you have a file, index.php. This file has an include statement for 'header.htm'.

Your question is does it matter if the header.htm is just HTML and does not contain and PHP?

No it does not matter. But the URL must be pointed to the index.php PHP page to process the actual
include() PHP command thus pulling in the header.htm page. 

Also, in the include statement the page you are including, in this case header.htm. does not have
to even be named .php, .htm etc. It can be .txt. But this is not only bad design but also a
security risk. 

Paul




--- Michael Adams <linux_mike@xxxxxxxxxxxxxxx> wrote:

> A real PHP newbie here.
> 
> I have so far only used the include statement in my site.
> Each page on the server loads a common header and footer. The header
> contains the site menu and the footer contains a line of logos in
> one graphic that <map>.
> 
> My query is:
> If i load the header as .HTM does it put the included file through the
> PHP parser. I have the includes as .PHP at present. There is nothing php
> in the header or footer as yet. I am looking at saving the server
> some cycles by doing this.
> 
> Michael
> 
> -- 
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 

-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux