PDA

View Full Version : Okay, I've a nutty question...don't laugh



Kathy
Fri 30th Jun '00, 9:53pm
I love the speed of my VB and know that this is a great help to my site. (Thanks John and James!)

Okay, the rest of my site is on the big side...when I have to update links, I have to do it to every page on the rest of the static pages...all html.

Could I use a hacked version of VB to create my content pages....with the header, footer and then content that I alone can input (creating a non-bulletin board template) and then add links to my index page? This way I can update the header of my site and footer (with all the links current with one change instead of hundreds)?

Is this nuts?

I'm thinking in the long run I need to have my ever growing site easy to edit....

If it isn't a hacked up VB, what am I looking for? (and no, I HATE frames)

JimF
Fri 30th Jun '00, 11:19pm
You don't necessarily have to hack up the vB, you can do regular includes with PHP. For example, I just put footers on all my pages today. I went through and put the following code at the very end of every page:



<?php
include("footer.inc")
?>


The file, footer.inc, is just the table tags - no <html> or <body> tags. Don't forget to make it relative to the directory ("../../footer.inc" vs. "footer.inc")

Then every page will display the same footer, and I only have to edit the "footer.inc" file when I need to change something.

Prior to using PHP, I used SSI (Server Side Includes) do the same thing, except the code for that is:



<!--#Include Virtual "footer.inc"-->


Hope this helps :)

-jim

Susan
Tue 4th Jul '00, 1:05pm
Thanks Jim! I got this all figured out and Kathy and I will be adding the headers and footers to all the pages soon. One last time of editing everything and then we're in business! A friend of mine and I were trying to figure out how to do this about a year ago and never did figure it out. Now, I have to send her email...:D Thanks for making me look somewhat slow on the draw, but brilliant, nonetheless.

Susan