Changing squid error pages

If you use squid to filter pages you will know about the ugly default error messages are. To change them you will need to edit the templates in the squid's errors directory.

On slackware this directory is located at: /usr/share/squid/errors/English; (For the english templates).

Just edit the HTML as you like and add the %s placeholder so squid does not add it's own footer to the template, You will need to restart squid so any changes will take effect.

Here is an example access denied error:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "">
                <TITLE>ERROR: Access Denied</TITLE>
                <style type="text/css">
                        BODY {
                                background-color: black;
                                color: #FFFFFF;
                <b>Access Denied</b> to <A HREF="%U">URL</A><br>

Last updated: 29/11/2005