]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Revert active part of error page stylesheets.
authorAmos Jeffries <squid3@treenet.co.nz>
Tue, 30 Sep 2008 06:36:50 +0000 (18:36 +1200)
committerAmos Jeffries <squid3@treenet.co.nz>
Tue, 30 Sep 2008 06:36:50 +0000 (18:36 +1200)
Strange Install blocker bug found. No solution yet.

(19:04:54) rousskov: 2008/09/30 00:05:20| errorpage.cc(290) errorTryLoadText:
 '/usr/local/squid3-ecap/share/errors/templates//usr/local/squid3-ecap/etc/errorpage.css':
 (2) No such file or directory
(19:07:52) rousskov: $ make install > /tmp/tm
(19:07:52) rousskov: /bin/bash: -c: line 17: syntax error near unexpected token `then'
(19:07:52) rousskov: /bin/bash: -c: line 17: `@if test -f /usr/local/squid3-ecap/etc/errorpage.css ; then \'

errors/Makefile.am
errors/errorpage.css [deleted file]
src/Makefile.am
src/cf.data.pre
src/errorpage.cc
src/errorpage.h
src/structs.h

index 79839d25aa6e28f01b559ad1b0acb6d997926351..6c53194645271369b5d616a28118939723d1148a 100644 (file)
@@ -9,8 +9,6 @@ errordir = $(datadir)/errors
 ##dist-hook eveything
 
 DEFAULT_ERROR_DIR      = $(errordir)
-DEFAULT_STYLESHEET     = $(sysconfdir)/errorpage.css
-
 
 # List of automated translations possible:
 TRANSLATIONS = \
@@ -72,15 +70,7 @@ install-data-local:
                        $(INSTALL_DATA) $$f $(DESTDIR)$(DEFAULT_ERROR_DIR)/$$l; \
                done; \
          fi \
-       done; \
-        $(INSTALL_DATA) $(srcdir)/errorpage.css $(DEFAULT_STYLESHEET).default; \
-        @if test -f $(DEFAULT_STYLESHEET) ; then \
-                echo "$@ will not overwrite existing $(DEFAULT_STYLESHEET)" ; \
-        else \
-                echo "$(INSTALL_DATA) $(srcdir)/errorpage.css $(DEFAULT_STYLESHEET)"; \
-                $(INSTALL_DATA) $(srcdir)/errorpage.css $(DEFAULT_STYLESHEET); \
-        fi
-
+       done
 
 uninstall-local:
        @ for l in $(LANGUAGES); do \
@@ -94,8 +84,7 @@ uninstall-local:
                        rm -f $(DESTDIR)$(DEFAULT_ERROR_DIR)/$$l/`basename $$f`; \
                done; \
          fi \
-       done; \
-       rm -f $(DEFAULT_STYLESHEET).default
+       done
 
 # undocumented hack.  You can use this target to create multi-lingual
 # error pages.  For example:
@@ -141,8 +130,7 @@ dist-hook:
                cp -p $(srcdir)/$$lang/ERR_*  $(distdir)/$$lang \
                  || exit 1; \
          fi; \
-       done; \
-       cp $(srcdir)/errorpage.css  $(distdir)/errorpage.css
+       done
 
 translate:
        @ if test "$(PO2HTML)" != "" ; then \
diff --git a/errors/errorpage.css b/errors/errorpage.css
deleted file mode 100644 (file)
index 2774114..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-
-// page basics
-html body {
-    background-color:#ffffff;
-    font-family:verdana,sans-serif
-}
-
-// initial title
-h1 {
-}
-
-// page sub-title
-h2 {
-}
-
-// general text
-p {
-}
-
-// error brief description
-#error p {
-}
-
-// some data which may have caused the prblem
-#data {
-}
-
-// the error message received from the system or other software
-#sysmsg {
-}
-
-
-pre {
-    font-family:sans-serif
-}
-
-// horizontal lines
-hr {
-}
-
-// page footer
-#footer {
-}
-
-// special event: FTP success page titles
-ftpsuccess {
-   background-color:#00ff00;
-   width:100%
-}
index 23ac933c51c2199cd71c6c969141ed0fcbe44725..d16a8c4f37dc9a412cfc03e74e2a50e6448ff707 100644 (file)
@@ -1043,7 +1043,6 @@ DEFAULT_HTTP_PORT = @CACHE_HTTP_PORT@
 DEFAULT_ICP_PORT       = @CACHE_ICP_PORT@
 DEFAULT_PREFIX         = $(prefix)
 DEFAULT_CONFIG_FILE     = $(sysconfdir)/squid.conf
-DEFAULT_CONFIG_DIR     = $(sysconfdir)
 DEFAULT_MIME_TABLE     = $(sysconfdir)/mime.conf
 DEFAULT_DNSSERVER       = $(libexecdir)/`echo dnsserver | sed '$(transform);s/$$/$(EXEEXT)/'`
 DEFAULT_LOG_PREFIX     = $(localstatedir)/logs
@@ -1117,7 +1116,6 @@ cf.data: cf.data.pre Makefile
        s%@DEFAULT_ICON_DIR@%$(DEFAULT_ICON_DIR)%g;\
        s%@DEFAULT_MIB_PATH@%$(DEFAULT_MIB_PATH)%g;\
        s%@DEFAULT_ERROR_DIR@%$(DEFAULT_ERROR_DIR)%g;\
-       s%@DEFAULT_CONFIG_DIR@%$(DEFAULT_CONFIG_DIR)%g;\
        s%@DEFAULT_PREFIX@%$(DEFAULT_PREFIX)%g;\
        s%@DEFAULT_HOSTS@%$(DEFAULT_HOSTS)%g;\
        s%@[V]ERSION@%$(VERSION)%g;"\
index 35147c010032487a6878e0c71a914ceb38909942..36d9e97c75ef062b2fec7ddb1501eecf02e2d787 100644 (file)
@@ -4800,16 +4800,6 @@ DOC_START
        of is error page translations.
 DOC_END
 
-NAME: err_page_stylesheet
-TYPE: string
-LOC: Config.errorStylesheet
-DEFAULT: @DEFAULT_CONFIG_DIR@/errorpage.css
-DOC_START
-       CSS Stylesheet to pattern the display of Squid default error pages.
-
-       For information on CSS see http://www.w3.org/Style/CSS/
-DOC_END
-
 NAME: err_html_text
 TYPE: eol
 LOC: Config.errHtmlText
index 29eedb4e02d8c1443d9447698a528dd12b688404..21f2926a29b4609bd77fa2a0b4eda012d790ae8d 100644 (file)
@@ -122,9 +122,6 @@ static char **error_text = NULL;
 /// \ingroup ErrorPageInternal
 static int error_page_count = 0;
 
-/// \ingroup ErrorPageInternal
-static MemBuf error_stylesheet;
-
 static char *errorTryLoadText(const char *page_name, const char *dir, bool silent = false);
 static char *errorLoadText(const char *page_name);
 static const char *errorFindHardText(err_type type);
@@ -185,17 +182,6 @@ errorInitialize(void)
             }
         }
     }
-
-    error_stylesheet.reset();
-
-    // look for and load stylesheet into global MemBuf for it.
-    if(Config.errorStylesheet) {
-        char *temp = errorLoadText(Config.errorStylesheet);
-        if(temp) {
-            error_stylesheet.Printf("%s",temp);
-            safe_free(temp);
-        }
-    }
 }
 
 void
@@ -688,11 +674,6 @@ ErrorState::Convert(char token)
 
         break;
 
-    case 'l':
-        mb.append(error_stylesheet.content(), error_stylesheet.contentSize());
-        do_quote = 0;
-        break;
-
     case 'L':
         if (Config.errHtmlText) {
             mb.Printf("%s", Config.errHtmlText);
index 62399db0401f8eca269fae8086cb195836e397fc..243782ffd2616ca8dd86701725bdf933b221c1c9 100644 (file)
@@ -59,7 +59,6 @@
    H - server host name                         x
    i - client IP address                        x
    I - server IP address                        x
-   l - HREF link for CSS stylesheet inclusion   x
    L - HREF link for more info/contact          x
    M - Request Method                           x
    m - Error message returned by auth helper    x
index 2d8621b35ed97e20b32f7df3ab3a48601e686965..d47164f6d97b0acdfd9f3da740e05cbae95dc0ad 100644 (file)
@@ -552,7 +552,6 @@ struct SquidConfig
     char *errorDefaultLanguage;
     int errorLogMissingLanguages;
 #endif
-    char *errorStylesheet;
 
     struct
     {