Topic: Using ssi?

Hi,

I have an SSI command that I use to pull p a top header on every page of my site. I would like this header added to the forum with the same ssi tag - however it does not appear that Punbb supports ssi? Has anyone run into this problem?

Chris

Re: Using ssi?

Whould it be possible to do a php include rather than a SSI? It would probably make more sense to do that in the long run.

require '<file_location>';

If you insist on doing the SSI, make sure that the server side include is in the 'header.php' file, since templates do not evaluate any kind of code.

~Creaturecorp

I don't HAVE a signature, ok?

Re: Using ssi?

Hey - thanks for the response. I am not very familiar with PHP so do you mind if I ask you a few questions...

Would I have to rename all the files that used this tag to a .php extension?
Is it possible to include this php tag in an html file?
In file_location how does it want me to specify the location if the file is located in another folder. ie. url, virtual path etc...

Thanks!

Chris

Re: Using ssi?

I just did some research and if I tried using php or asp I would have to end each file in that extension changing it from the .html

This would require alot of rewriting in several different programs so I have to figure out how to do it in ssi. Anyone have any ideas?

Chris

5

Re: Using ssi?

You don't need to update your whole site, only the punbb code.

Let's say you're using this ssi tag right after the <body> part of your pages:

<!--#include virtual="/includes/header.html" -->

And you've got your punbb installed at:

http://www.example.com/forum/

Then you should look for:

// END SUBST - <body>

in header.php, and right after that, enter the following:

include_once '../includes/header.html';


That's it... smile

Re: Using ssi?

Wow! I love quick and easy solutions!!!!! Your awesome Sjon - Thanks!