Hi, I followed the instructions in localized-error-pages.conf to setup localized error pages, but found out that page content under /error/include/ are not preprocessed before sent to client.
Example: ```` <!--#if expr="-z v('CONTENT_LANGUAGE')" --><!--#set var="CONTENT_LANGUAGE" value="en" --><!--#endif --><?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="<!--#echo var="CONTENT_LANGUAGE" -->" xml:lang="<!--#echo var="CONTENT_LANGUAGE" -->"> <head> <title><!--#echo encoding="none" var="TITLE" --></title> <link rev="made" href="mailto:<!--#echo encoding="url" var="SERVER_ADMIN" -->" /> <style type="text/css"><!--/*--><![CDATA[/*><!--*/ body { color: #000000; background-color: #FFFFFF; } a:link { color: #0000CC; } p, address {margin-left: 3em;} span {font-size: smaller;} /*]]>*/--></style> </head>
<body> <h1><!--#echo encoding="none" var="TITLE" --></h1> <p>
You don't have permission to access the requested directory. There is either no index document or the directory is read-protected.
</p> <p> <!--#include virtual="../contact.html.var" --> </p>
<h2>Error <!--#echo encoding="none" var="REDIRECT_STATUS" --></h2> <address> <a href="/"><!--#echo var="SERVER_NAME" --></a><br /> <span><!--#echo var="SERVER_SOFTWARE" --></span> </address> </body> </html> ````
It seems that the config template should include
```` <Directory "/var/www/localized-error-pages/"> Options IncludesNoExec AddOutputFilter Includes html Order allow,deny Allow from all </Directory>
````
after ````` Alias /error/include/ "/path" `````
to make it process correctly
Example: ``` <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <head> <title>Access forbidden!</title> <link rev="made" href="mailto:<email address hidden>" /> <style type="text/css"><!--/*--><![CDATA[/*><!--*/ body { color: #000000; background-color: #FFFFFF; } a:link { color: #0000CC; } p, address {margin-left: 3em;} span {font-size: smaller;} /*]]>*/--></style> </head>
<body> <h1>Access forbidden!</h1> <p>
</p> <p> If you think this is a server error, please contact the <a href="mailto:<email address hidden>">webmaster</a>.
</p>
<h2>Error 403</h2> <address> <a href="/">140.121.80.26</a><br /> <span>海洋大學網路發展協會網站托管服務</span> </address> </body> </html> ```
ProblemType: Bug DistroRelease: Ubuntu 14.04 Package: apache2 2.4.7-1ubuntu4.4 ProcVersionSignature: Ubuntu 3.13.0-39.66-generic 3.13.11.8 Uname: Linux 3.13.0-39-generic i686 NonfreeKernelModules: nvidia Apache2ConfdDirListing: False ApportVersion: 2.14.1-0ubuntu3.8 Architecture: i386 CurrentDesktop: KDE Date: Mon Apr 13 10:22:55 2015 SourcePackage: apache2 UpgradeStatus: No upgrade log present (probably fresh install) error.log: [Mon Apr 13 07:53:45.032576 2015] [mpm_event:notice] [pid 31758:tid 3074755200] AH00489: Apache/2.4.7 (Ubuntu) configured -- resuming normal operations [Mon Apr 13 07:53:45.032600 2015] [core:notice] [pid 31758:tid 3074755200] AH00094: Command line: '/usr/sbin/apache2' modified.conffile..etc.apache2.conf.available.security.conf: [modified] modified.conffile..etc.apache2.mods.available.userdir.conf: [modified] mtime.conffile..etc.apache2.conf.available.security.conf: 2015-04-13T07:51:58.965640 mtime.conffile..etc.apache2.mods.available.userdir.conf: 2014-12-24T22:54:46.119177
Hi, I followed the instructions in localized- error-pages. conf to setup localized error pages, but found out that page content under /error/include/ are not preprocessed before sent to client.
Example: LANGUAGE' )" LANGUAGE" value="en" www.w3. org/TR/ xhtml1/ DTD/xhtml1- strict. dtd"> www.w3. org/1999/ xhtml" lang="<!--#echo var="CONTENT_ LANGUAGE" -->" xml:lang="<!--#echo var="CONTENT_ LANGUAGE" -->"> <!--#echo encoding="url" var="SERVER_ADMIN" -->" /> css"><! --/*--> <![CDATA[ /*><!-- */
````
<!--#if expr="-z v('CONTENT_
--><!--#set var="CONTENT_
--><!--#endif
--><?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://
<html xmlns="http://
<head>
<title><!--#echo encoding="none" var="TITLE" --></title>
<link rev="made" href="mailto:
<style type="text/
body { color: #000000; background-color: #FFFFFF; }
a:link { color: #0000CC; }
p, address {margin-left: 3em;}
span {font-size: smaller;}
/*]]>*/--></style>
</head>
<body>
<h1><!--#echo encoding="none" var="TITLE" --></h1>
<p>
You don't have permission to access the requested directory.
There is either no index document or the directory is read-protected.
</p> "../contact. html.var" -->
<p>
<!--#include virtual=
</p>
<h2>Error <!--#echo encoding="none" var="REDIRECT_ STATUS" --></h2> SOFTWARE" --></span>
<address>
<a href="/"><!--#echo var="SERVER_NAME" --></a><br />
<span><!--#echo var="SERVER_
</address>
</body>
</html>
````
It seems that the config template should include
```` localized- error-pages/ ">
AddOutputFilte r Includes html
<Directory "/var/www/
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
````
after
`````
Alias /error/include/ "/path"
`````
to make it process correctly
Example: www.w3. org/TR/ xhtml1/ DTD/xhtml1- strict. dtd"> www.w3. org/1999/ xhtml" lang="en" xml:lang="en"> css"><! --/*--> <![CDATA[ /*><!-- */
```
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://
<html xmlns="http://
<head>
<title>Access forbidden!</title>
<link rev="made" href="mailto:<email address hidden>" />
<style type="text/
body { color: #000000; background-color: #FFFFFF; }
a:link { color: #0000CC; }
p, address {margin-left: 3em;}
span {font-size: smaller;}
/*]]>*/--></style>
</head>
<body>
<h1>Access forbidden!</h1>
<p>
You don't have permission to access the requested directory.
There is either no index document or the directory is read-protected.
</p> ">webmaster< /a>.
<p>
If you think this is a server error, please contact
the <a href="mailto:<email address hidden>
</p>
<h2>Error 403</h2> ">140.121. 80.26</ a><br /> 海洋大學網路發展協會網站托管服 務</span>
<address>
<a href="/
<span>
</address>
</body>
</html>
```
ProblemType: Bug ature: Ubuntu 3.13.0- 39.66-generic 3.13.11.8 dules: nvidia Listing: False conffile. .etc.apache2. conf.available. security. conf: [modified] conffile. .etc.apache2. mods.available. userdir. conf: [modified] .etc.apache2. conf.available. security. conf: 2015-04- 13T07:51: 58.965640 .etc.apache2. mods.available. userdir. conf: 2014-12- 24T22:54: 46.119177
DistroRelease: Ubuntu 14.04
Package: apache2 2.4.7-1ubuntu4.4
ProcVersionSign
Uname: Linux 3.13.0-39-generic i686
NonfreeKernelMo
Apache2ConfdDir
ApportVersion: 2.14.1-0ubuntu3.8
Architecture: i386
CurrentDesktop: KDE
Date: Mon Apr 13 10:22:55 2015
SourcePackage: apache2
UpgradeStatus: No upgrade log present (probably fresh install)
error.log:
[Mon Apr 13 07:53:45.032576 2015] [mpm_event:notice] [pid 31758:tid 3074755200] AH00489: Apache/2.4.7 (Ubuntu) configured -- resuming normal operations
[Mon Apr 13 07:53:45.032600 2015] [core:notice] [pid 31758:tid 3074755200] AH00094: Command line: '/usr/sbin/apache2'
modified.
modified.
mtime.conffile.
mtime.conffile.