asouthern0
07-26-2004, 06:53 PM
How do I make a generic layout, so that I just add different information for each page. Kind of like how frames work, just without the frame - if that makes sense?
Is it using php or cgi? Is there a script? ..
one way would be to use SSI or PHP includes.
divide your page up so it has the top part of your coding, and bottom part of your coding on seperate pages.
on a new page, "include" the top part page, type in your new information contents, then "include" the bottom part page. save it and you are done. if any changes are required in the top or bottom parts, you just have to edit one page, instead of all of your pages.
asouthern0
07-26-2004, 07:03 PM
I don't really understand what you mean. How would that work..? Do you link to it somehow?
Spirit892
07-26-2004, 07:17 PM
I think I can help:
A simple php include page could look something like the following.
<?php
include("header.php");
?>
ALL PAGE CONTENT GOES HERE
<?php
include("footer.php");
?>
The header holds the beginning of the page, the stylesheet, etc. The footer holds the end of the page, the closing tags, whatever. For each page, you just insert the header include at the top and the footer include at the bottom. Then upload the header and footer files to the same directory as your pages and it should work. :) Make sure that all the pages with the includes have a .php at the end. Hope that helps!
asouthern0
07-27-2004, 03:34 AM
oooh ok. That makes a lot more sense. Thanks guys!