- Last post
- 6 Responses
What is the best way to include a site-wide navigation and header across a big site?
1. Just html, same as usual? But that would be difficult to update.
2. Server side includes?
3. PHP include? This might be difficult because wouldn't I have to change all the file names to .php to get it to process?
I need to put a bandaid on about 400 pages to update the header so I want to do this the best way (and easiest to change again which will likely be soon).
You can also configure your server to process other page extensions as php.
^ in an htaccess file:
AddType application/x-httpd-php .html .htm
note that it will slow things down a bit as you're firing up the php engine to parse every .html page.
Is this how you would do it if starting clean as well? PHP includes? Or this seems the best considering that I need to change existing pages?
How much would it slow things down to process every page as php? Do you thing that is something that would be significant assuming a fair amount of traffic?