How can you make a page where you always use one header and one footer. So despite how many pages you have, you only have to edit one header and one footer and then it is automaticly applied to all the pages. How can this be done?
if your using php you could use. <?php include('header.php'); ?> PHP: <?php include('footer.php'); ?> PHP: place within file.php where you wish for header.php & footer.php to be shown. of course header & footer can be re-named to whatever you wish. so your page would look like <?php include('header.php'); ?> Main page content <?php include('footer.php'); ?> PHP:
Website is static or dynamic? For a static website, look in the programming forums for digitalpoints mod_rewrite hack, that let's you achieve it. Otherwise, look into mod_layout (both are for apache of course). If your website is dynamic, the easiest way would be to wrap the content around header and footer, so that it's only the content that change when loading different pages. From the question, I assume you don't have any programming experience, so I will not give any examples. Ask in the programming forum if you feel the need for them.
@just-4-teens That looks simple , so what if its html? @n0other What do you mean with static or dynamic?
You can use Server Side Includes as well. I have been using ASP mainly to take advanatge of the ASP include function. But SSI is pretty easy to implement and might be able to help you out
If its html you need to alter your .htaccess file to process html as a php file Static is page.html or page.php Dynamic is page.php?section=1
If its .html/.htm pages, then there is a way around it using .htaccess & mod_rewrite (you might find some info here http://forums.digitalpoint.com/forumdisplay.php?f=49) basicly what it does is parse static html pages as dynamic php. --- wait i found it Add this to your .htaccess file.
I guess it's already too late, but by dynamic I refer to a website which has its output generated on the go (or in other words dynamically, depending on user's actions usually)