* Cleanups to summary page when running on a non ical enabled system
authorArt Cancro <ajc@citadel.org>
Mon, 5 May 2003 17:19:46 +0000 (17:19 +0000)
committerArt Cancro <ajc@citadel.org>
Mon, 5 May 2003 17:19:46 +0000 (17:19 +0000)
* Use non breaking spaces in summary page box titles

webcit/ChangeLog
webcit/summary.c

index b04ab6459ea8b17e41604cb4a8d252e627fc31cf..c0fa2ec2aee3c50667f645ffdd3446ebcca83f6c 100644 (file)
@@ -1,4 +1,8 @@
 $Log$
+Revision 410.25  2003/05/05 17:19:46  ajc
+* Cleanups to summary page when running on a non ical enabled system
+* Use non breaking spaces in summary page box titles
+
 Revision 410.24  2003/05/04 04:22:41  ajc
 * Display body of messages on a white background.  I am doing this in order
   to prepare for making the general background of the screen a darker color.
@@ -1378,3 +1382,4 @@ Sun Dec  6 19:50:55 EST 1998 Art Cancro <ajc@uncnsrd.mt-kisco.ny.us>
 
 1998-12-03 Nathan Bryant <bryant@cs.usm.maine.edu>
        * webserver.c: warning fix
+
index 9b6555e2d5319457d6154c1a86fa5067e55fcd90..f1fb69db25820571e6afc1186b77f1a6fa875f22 100644 (file)
@@ -132,23 +132,29 @@ void tasks_section(void) {
 
        svprintf("BOXTITLE", WCS_STRING, "Tasks");
        do_template("beginbox");
+#ifdef WEBCIT_WITH_CALENDAR_SERVICE
        gotoroom("Tasks", 0);
        if (strcasecmp(WC->wc_roomname, "Tasks")) {
-               wprintf("<i>(You do not have a task list)</i><BR>\n");
-               return;
+               num_msgs = 0;
+       }
+       else {
+               num_msgs = load_msg_ptrs("MSGS ALL");
        }
 
-       num_msgs = load_msg_ptrs("MSGS ALL");
        if (num_msgs < 1) {
                wprintf("<i>(None)</i><BR>\n");
-               return;
        }
-
-       wprintf("<UL>");
-       for (i=0; i<num_msgs; ++i) {
-               display_task(WC->msgarr[i]);
+       else {
+               wprintf("<UL>");
+               for (i=0; i<num_msgs; ++i) {
+                       display_task(WC->msgarr[i]);
+               }
+               wprintf("</UL>\n");
        }
-       wprintf("</UL>\n");
+
+#else /* WEBCIT_WITH_CALENDAR_SERVICE */
+       wprintf("<I>(This server does not support task lists)</I>\n");
+#endif /* WEBCIT_WITH_CALENDAR_SERVICE */
        do_template("endbox");
 }
 
@@ -165,21 +171,24 @@ void calendar_section(void) {
 #ifdef WEBCIT_WITH_CALENDAR_SERVICE
        gotoroom("Calendar", 0);
        if (strcasecmp(WC->wc_roomname, "Calendar")) {
-               wprintf("<i>(You do not have a calendar)</i><BR>\n");
-               return;
+               num_msgs = 0;
+       }
+       else {
+               num_msgs = load_msg_ptrs("MSGS ALL");
        }
 
-       num_msgs = load_msg_ptrs("MSGS ALL");
        if (num_msgs < 1) {
                wprintf("<i>(Nothing)</i><BR>\n");
-               return;
        }
-
-       for (i=0; i<num_msgs; ++i) {
-               display_calendar(WC->msgarr[i]);
+       else {
+               for (i=0; i<num_msgs; ++i) {
+                       display_calendar(WC->msgarr[i]);
+               }
+               calendar_summary_view();
        }
 
-       calendar_summary_view();
+#else /* WEBCIT_WITH_CALENDAR_SERVICE */
+       wprintf("<I>(This server does not support calendars)</I>\n");
 #endif /* WEBCIT_WITH_CALENDAR_SERVICE */
        do_template("endbox");
 }