1 |
On 06/11/12 12:54, Peter Humphrey wrote: |
2 |
> OK, I've added that to 00_default_settings.conf. I'm not sure whether I |
3 |
> need rewrites though. |
4 |
> |
5 |
|
6 |
Your htaccess had some rewrite rules, that's why I suggested it. |
7 |
|
8 |
|
9 |
> The fog is beginning to clear. Thanks. |
10 |
> |
11 |
> I still can't get server-side includes to work though. Modules.d/*.conf |
12 |
> don't include a suitable module. I've added "-D INCLUDE" to APACHE2_OPTS |
13 |
> in /etc/conf.d/apache2.conf but it seems not to be enough. |
14 |
|
15 |
We have this working here.. let's see. |
16 |
|
17 |
First of all, I see you have the mime module compiled; that's good. Is |
18 |
it enabled? You should have, |
19 |
|
20 |
LoadModule mime_module modules/mod_mime.so |
21 |
|
22 |
in httpd.conf. |
23 |
|
24 |
Once the mime module is enabled, everything in |
25 |
modules.d/00_mod_mime.conf will be processed (it's conditional on the |
26 |
existence of the mime module). |
27 |
|
28 |
Then, you should add or uncomment the following in 00_mod_mime.conf: |
29 |
|
30 |
# Filters allow you to process content before it is sent to the |
31 |
# client |
32 |
# |
33 |
# To parse .shtml files for server-side includes(SSI): |
34 |
# (You will also need to add "Includes" to the "Options" |
35 |
# directive.) |
36 |
AddType text/html .shtml |
37 |
AddOutputFilter INCLUDES .shtml |
38 |
|
39 |
That will enable server-side includes in *.shtml files, assuming you |
40 |
also add "Includes" to the relevant "Options" directive. |
41 |
|
42 |
If you need server-side includes for other types of files, it isn't |
43 |
recommended[1], but you can add additional "AddOutputFilter" directives |
44 |
for each type of file you'd like SSI to work with. |
45 |
|
46 |
|
47 |
|
48 |
[1] http://httpd.apache.org/docs/2.2/howto/ssi.html |