cancel
Showing results for 
Search instead for 
Did you mean: 

SSI: differences between Tomcat and Apache

marcus
Champ in-the-making
Champ in-the-making
I'm trying to use SSI to be able to manage my site templates a little cleaner, but am having some problems when it comes to using conditionals that are consistent between Apache and Tomcat. For example, the following is True on Apache


<!–#if expr="$DATE_LOCAL = /day/"–>

but fails on Tomcat, whereas the following


<!–#if expr="$DATE_LOCAL" = /day/–>

is true on Tomcat but fails on Apache.

Has anyone got some examples of string comparison conditionals that work the same on apache as tomcat? So far I'm coming up short 😕

Edit: I should be a bit clearer, exact matching eg expr="$variable = string" works on both, but regex matching doesn't for some weird reason.
1 REPLY 1

arielb
Champ in-the-making
Champ in-the-making
this isn't something i've ever tried - but please refer to the tomcat docs on SSIs here http://tomcat.apache.org/tomcat-5.5-doc/ssi-howto.html (if you haven't already).  a cursory glance indicates that what you're trying to do should work…