Yes, I know the standard response is, "Just change them to PHP includes." I'm hoping I don't have to do that.

I'm currently running on Apache 1.3.

I have a site that is 95% static pages. I'm using Dreamweaver templates and SSI to maintain consistency across the site.

I do have a few forms that the user will want some feedback on. I would like to layout the output pages using the same architecture I'm using now.

It strikes me that the most robust way to do that would be to find a template system that knows how to parse Apache SSIs. Does anyone know of such a beast?

Alternatively, could a regex expert help me come up with a code snippet that'll convert an Apache include to a PHP include?

Thanks.

    Hmm have you tried searching for an SSI templating system?

    I dont know of any so there probably will be very little.

    Also no one can help you if you dont show us what the SSI's look like not every single one just what each is used for. There are quite a few Apache SSI commands to use I doubt there is a PHP system that has them all there ready for converting but you could consult http://hotscripts.com to maybe find one.

      Yes, I've searched around for a few hours over a few different evenings. I've come across a few threads like this and they always stop at recommending converting the includes to PHP. I have yet to find one that understands Apache includes.

      At this point, that's all I need. To convert #include virtual to include().

        Maybe convert them to [man]virtual[/man]?

          The trick is SSI gets processed BEFORE PHP. This is fine. But when you want to control what gets sent to the browser, you're at the mercy of SSI and how you set it up instead of using the power of PHP.

          If you can still work with SSI, cool. But I would think you'd have a lot more power and control over your content if you went with a PHP driven solution. You could use templates which would keep the PHP seperate from the HTML. It takes a lot of effort to get setup, but once established, any updates are effortless.

            I completely understand what you're saying. At some point, I'll likely find a CMS to handle this site. But at the moment, the setup I have fits my needs pretty well. All except this one facet.

            I know I want a template system to present the output of my PHP scripts. It strikes me that a simple template system that knows how to interpret Apache includes is exactly what I need right now.

              Write a Reply...