Home: Need a Custom or Prewritten Perl Program?: I need a program that...:
Insert page headers via SSI?



Skorpion
Deleted

Sep 8, 2000, 11:01 AM


Views: 2390
Insert page headers via SSI?

On my site, I've got a fairly complicated layout that is uniform throughout my site. And since I've got a largish number of pages, when I want to update part of the layout it usually takes a long time.

Is there a program out there that lets me, say, put the entire layout of the page in a text file, and then have an SSI call at the top of each page that will automatically fill in the layout dynamically? That way I can edit the layout once, and have the changes reflected on all pages automatically.

Possibly it may be required to actually have two different scripts: one for everything ABOVE the page content, and one for everything BELOW the page content. That's the way the UBB program does it: there is a header field, and there is a footer field, and it gets split into two separate parts like that.

Thanks in advance for any help you can provide!

---Skorpion


fashimpaur
User

Sep 8, 2000, 12:51 PM


Views: 2390
Re: Insert page headers via SSI?

I don't think you need a Perl program to do that.

Create the html for everything above the content. Save it.

Create the html for everything below the
content. Save it.

then, an shtml file looks like this:

<BLOCKQUOTE><font size="1" face="Arial,Helvetica,sans serif">code:</font><HR>


<HTML>
<!--#include file="top_layout.html" -->

<H1> Hello World! </H1>

<!--#include file="bottom_layout.html" -->
</HTML>
</pre><HR></BLOCKQUOTE>

You may even be able to configure your web server to handle .htm files on the site as
.shtml files and then no one is any wiser that you are using shtml or to confuse them if they forget to put in the .shtml extention.

HTH,

Dennis


Skorpion
Deleted

Sep 8, 2000, 3:57 PM


Views: 2390
Re: Insert page headers via SSI?

Wow, it's that easy? Now I kinda feel stupid. Oh well. Thanks a lot for the info! I'll go try it now.

---Skorpion