Summary Banner : HTML/CSS simplification
authorThierry Pasqualier <thierry@uncensored.citadel.org>
Sun, 20 May 2007 14:57:53 +0000 (14:57 +0000)
committerThierry Pasqualier <thierry@uncensored.citadel.org>
Sun, 20 May 2007 14:57:53 +0000 (14:57 +0000)
I would like to handle in the same way all the banners
of services and administration screens
at the end to reduce the number of classes CSS

webcit/static/webcit.css
webcit/summary.c

index f7dcfa7cb57c9861805b53b1659a3caa286dbee8..184c509198e41e3b7dce058b2b1eb117fd938853 100644 (file)
@@ -71,13 +71,12 @@ body {
        background: #445;
 }
 
-
-#banner .room_banner {
+#banner .room_banner, #banner .service_banner {
         float: left;
         width: 48%;
 }
 
-.room_banner img {
+.room_banner img,  .service_banner img {
         float: left;
         margin-top: 0;
         margin-left: 0;
@@ -93,6 +92,20 @@ body {
         padding: 2px;
 }
 
+.service_banner h1 {
+        font-size: 12pt;
+        font-weight: bold;
+        color: #FFFFEE;
+        margin: 0;
+        padding: 2px;
+}
+
+.service_banner h2 {
+        font-size: 11pt;
+        font-weight: bold;
+        color: #FFFFEE;
+}
+
 .room_banner .infos {
         font-size: 8pt;
        color: #FFFFEE;
@@ -845,7 +858,7 @@ div.auto_complete ul strong.highlight {
         background-color: #444455;
 }
 
-.smtpqueue_banner, .summary_banner, .useredit_banner, .userlist_banner, .downloads_banner, .vcard_edit_banner, .who_banner, .room_banner   {
+.smtpqueue_banner, .useredit_banner, .userlist_banner, .downloads_banner, .vcard_edit_banner, .who_banner, .room_banner   {
         border: 0;
         width: 100%;
         background-color: #444455;
index 13dfdf70abca7e2bc4d2bda46677ca73bed42747..95fa8a8a418cb025b28c005b696eb40cade0af43 100644 (file)
@@ -251,26 +251,25 @@ void summary(void) {
 
        output_headers(1, 1, 2, 0, 0, 0);
        wprintf("<div id=\"banner\">\n");
-       wprintf("<table class=\"summary_banner\"><tr>"
-               "<td><img src=\"static/summscreen_48x.gif\"></td><td>"
-               "<span class=\"titlebar\">"
-       );
-
-       snprintf(title, sizeof title, _("Summary page for %s"), WC->wc_fullname);
-       escputs(title);
-       wprintf("</span></td><td>\n");
-       wprintf("</td><td aling=right><span class=\"titlebar\">");
-       output_date();
-       wprintf("</span><br />");
-       offer_start_page();
-       wprintf("</td></tr></table>\n");
+        wprintf("<div class=\"service_banner\">\n");
+        wprintf("<img src=\"static/summscreen_48x.gif\">");
+        wprintf("<h1>");
+        snprintf(title, sizeof title, _("Summary page for %s"), WC->wc_fullname);
+        escputs(title);
+        wprintf("</h1><h2>\n");
+        output_date();
+        wprintf("</h2></div>");
+        wprintf("<ul><li class=\"start_page\">");
+        offer_start_page();
+        wprintf("</li></ul>");
+        wprintf("</div>");
 
        /**
         * You guessed it ... we're going to refresh using ajax.
         * In the future we might consider updating individual sections of the summary
         * instead of the whole thing.
         */
-       wprintf("</div>\n<div id=\"content\">\n");
+       wprintf("<div id=\"content\">\n");
        summary_inner_div();
        wprintf("</div>\n");