=== modified file 'errors/Makefile.am'
--- errors/Makefile.am	2010-10-27 23:29:55 +0000
+++ errors/Makefile.am	2010-11-20 05:35:01 +0000
@@ -138,7 +138,9 @@
 		$(mkinstalldirs) $(DESTDIR)`dirname $(DEFAULT_STYLESHEET)` ; \
 		echo "$(INSTALL_DATA) $(srcdir)/errorpage.css $(DESTDIR)$(DEFAULT_STYLESHEET)"; \
 		$(INSTALL_DATA) $(srcdir)/errorpage.css $(DESTDIR)$(DEFAULT_STYLESHEET); \
-	fi
+	fi; \
+	$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/errors.d; \
+	$(LN) -s $(DESTDIR)$(sysconfdir)/errors.d $(DESTDIR)$(DEFAULT_ERROR_DIR)/local
 
 install-data-local: translate
 	$(mkinstalldirs) $(DESTDIR)$(DEFAULT_ERROR_DIR) ; \
@@ -187,6 +189,7 @@
 	rm -f $(DESTDIR)$(DEFAULT_STYLESHEET).default
 	rm -f $(DESTDIR)$(DEFAULT_ERROR_DIR)/TRANSLATORS
 	rm -f $(DESTDIR)$(DEFAULT_ERROR_DIR)/COPYRIGHT
+	rm -f $(DESTDIR)$(DEFAULT_ERROR_DIR)/local
 
 ## Upgrade requires the new files to be pre-installed
 upgrade: install

=== modified file 'src/cache_cf.cc'
--- src/cache_cf.cc	2010-11-19 12:04:58 +0000
+++ src/cache_cf.cc	2010-11-20 05:32:19 +0000
@@ -698,8 +698,10 @@
 
     requirePathnameExists("Icon Directory", Config.icons.directory);
 
-    if (Config.errorDirectory)
+    if (Config.errorDirectory) {
+        debugs(0,0, "WARNING: error_directory is deprecated. Place local error templates in /etc/squid/errors.d/");
         requirePathnameExists("Error Directory", Config.errorDirectory);
+    }
 
 #if USE_HTTP_VIOLATIONS
 

=== modified file 'src/errorpage.cc'
--- src/errorpage.cc	2010-11-01 05:44:28 +0000
+++ src/errorpage.cc	2010-11-20 05:27:28 +0000
@@ -246,6 +247,10 @@
     if (Config.errorDirectory)
         text = errorTryLoadText(page_name, Config.errorDirectory);
 
+    /* test custom pages location in case we have an override page */
+    if (!text)
+        text = errorTryLoadText(page_name, DEFAULT_SQUID_ERROR_DIR"/local");
+
 #if USE_ERR_LOCALES
     /** test error_default_language location */
     if (!text && Config.errorDefaultLanguage) {
@@ -992,6 +1016,10 @@
      */
     if (!Config.errorDirectory && page_id < ERR_MAX && request && request->header.getList(HDR_ACCEPT_LANGUAGE, &hdr) ) {
 
+        // pull override from the local custom templates directory if present.
+        if ((m = errorTryLoadText(err_type_str[page_id], DEFAULT_SQUID_ERROR_DIR"/local", true)))
+            break;
+
         size_t pos = 0; // current parsing position in header string
         char *reset = NULL; // where to reset the p pointer for each new tag file
         char *dt = NULL;

=== modified file 'src/cf.data.pre'
--- src/cf.data.pre	2010-11-18 08:01:53 +0000
+++ src/cf.data.pre	2010-11-20 05:50:48 +0000
@@ -5805,22 +5805,13 @@
 LOC: Config.errorDirectory
 DEFAULT: none
 DOC_START
-	If you wish to create your own versions of the default
-	error files to customize them to suit your company copy
-	the error/template files to another directory and point
-	this tag at them.
-
-	WARNING: This option will disable multi-language support
-	         on error pages if used.
-
-	The squid developers are interested in making squid available in
-	a wide variety of languages. If you are making translations for a
-	language that Squid does not currently provide please consider
-	contributing your translation back to the project.
-	http://wiki.squid-cache.org/Translations
-
-	The squid developers working on translations are happy to supply drop-in
-	translated error files in exchange for any new language contributions.
+	This option was used to point Squid at the location of local
+	customized error templates. This is now deprecated.
+
+	Squid loads custom templates from /etc/squid/errors.d/
+
+	WARNING: This option will disable multi-language support on
+	         error pages if used.
 DOC_END
 
 NAME: error_default_language

