Rename show-client-tags template to client-tags
authorFabian Keil <fk@fabiankeil.de>
Mon, 4 Apr 2016 10:55:47 +0000 (10:55 +0000)
committerFabian Keil <fk@fabiankeil.de>
Mon, 4 Apr 2016 10:55:47 +0000 (10:55 +0000)
The page doesn't merely show the tags but also allows to
enable or disable them. While at it, make the page title
more descriptive.

cgi.c
cgisimple.c
templates/client-tags [moved from templates/show-client-tags with 97% similarity]

diff --git a/cgi.c b/cgi.c
index 759517d..76f3f22 100644 (file)
--- a/cgi.c
+++ b/cgi.c
@@ -1,4 +1,4 @@
-const char cgi_rcs[] = "$Id: cgi.c,v 1.162 2016/03/17 10:40:53 fabiankeil Exp $";
+const char cgi_rcs[] = "$Id: cgi.c,v 1.163 2016/03/30 11:14:05 fabiankeil Exp $";
 /*********************************************************************
  *
  * File        :  $Source: /cvsroot/ijbswa/current/cgi.c,v $
@@ -101,7 +101,7 @@ static const struct cgi_dispatcher cgi_dispatchers[] = {
          "View the source code version numbers",
           TRUE },
 #ifdef FEATURE_CLIENT_TAGS
-   { "show-client-tags",
+   { "client-tags",
          cgi_show_client_tags,
          "View or toggle the tags that can be set based on the clients address",
           FALSE },
index c9aa66a..8000af4 100644 (file)
@@ -1,4 +1,4 @@
-const char cgisimple_rcs[] = "$Id: cgisimple.c,v 1.136 2016/03/17 10:40:53 fabiankeil Exp $";
+const char cgisimple_rcs[] = "$Id: cgisimple.c,v 1.137 2016/04/04 10:51:45 fabiankeil Exp $";
 /*********************************************************************
  *
  * File        :  $Source: /cvsroot/ijbswa/current/cgisimple.c,v $
@@ -310,7 +310,7 @@ static void cgi_create_client_tag_form(char *form, size_t size,
    }
 
    snprintf(form, size,
-      "<form method=\"GET\" action=\"show-client-tags\" style=\"display: inline\">\n"
+      "<form method=\"GET\" action=\"client-tags\" style=\"display: inline\">\n"
       " <input type=\"hidden\" name=\"tag\" value=\"%s\">\n"
       " <input type=\"hidden\" name=\"toggle-state\" value=\"%u\">\n"
       " <input type=\"hidden\" name=\"expires\" value=\"%u\">\n"
@@ -354,7 +354,7 @@ jb_err cgi_show_client_tags(struct client_state *csp,
    assert(rsp);
    assert(parameters);
 
-   if (NULL == (exports = default_exports(csp, "show-client-tags")))
+   if (NULL == (exports = default_exports(csp, "client-tags")))
    {
       return JB_ERR_MEMORY;
    }
@@ -439,7 +439,7 @@ jb_err cgi_show_client_tags(struct client_state *csp,
       return JB_ERR_MEMORY;
    }
 
-   return template_fill_for_cgi(csp, "show-client-tags", exports, rsp);
+   return template_fill_for_cgi(csp, "client-tags", exports, rsp);
 }
 #endif /* def FEATURE_CLIENT_TAGS */
 
similarity index 97%
rename from templates/show-client-tags
rename to templates/client-tags
index ab1d1d4..4e9f021 100644 (file)
@@ -1,6 +1,6 @@
 ##########################################################
 #
-# Show-Request-CGI Output template for Privoxy.
+# client-tags template for Privoxy.
 #
 #
 # USING HTML TEMPLATES:
@@ -74,7 +74,7 @@
 <html>
 
 <head>
-  <title>Privoxy@@my-hostname@</title>
+  <title>Available client tags - Privoxy@@my-hostname@</title>
   <meta http-equiv="Content-Style-Type" content="text/css">
   <meta http-equiv="Content-Script-Type" content="text/javascript">
   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 
     <tr>
       <td class="box">
-       <h2>Show client tags</h2>
+       <h2>Available client tags</h2>
           <p>
             This page shows the configured
             <a title="Lookup client-specific-tag directive in the user-manual"