* Replaced all the "centered 99% tables" with 100% width tables wrapped
[citadel.git] / webcit / messages.c
index 5092c6abce64ffbb326c43c13e294f3802159684..123c894602f681d00ffb3ee84d602b5e2d47e150 100644 (file)
@@ -103,6 +103,11 @@ void fetchname_parsed_vcard(struct vCard *v, char *storename) {
        if (v->numprops) for (i=0; i<(v->numprops); ++i) {
                if (!strcasecmp(v->prop[i].name, "n")) {
                        strcpy(storename, v->prop[i].value);
+                       if ((strlen(storename)>0) && (storename[0] != ';')) {
+                               while(storename[strlen(storename)-1] == ';') {
+                                       storename[strlen(storename)-1] = 0;
+                               }
+                       }
                }
        }
 }
@@ -142,10 +147,11 @@ void display_parsed_vcard(struct vCard *v, int full) {
        if (!full) {
                wprintf("<TD>");
                name = vcard_get_prop(v, "fn", 1, 0, 0);
-               if (name == NULL) name = vcard_get_prop(v, "n", 1, 0, 0);
                if (name != NULL) {
-                       strcpy(buf, name);
-                       escputs(buf);
+                       escputs(name);
+               }
+               else if (name = vcard_get_prop(v, "n", 1, 0, 0), name != NULL) {
+                       escputs(name);
                }
                else {
                        wprintf("&nbsp;");
@@ -206,7 +212,7 @@ void display_parsed_vcard(struct vCard *v, int full) {
                        }
        
                        else if (!strcasecmp(firsttoken, "email")) {
-                               if (strlen(mailto) > 0) strcat(mailto, "<BR>");
+                               if (strlen(mailto) > 0) strcat(mailto, "<br />");
                                strcat(mailto,
                                        "<A HREF=\"/display_enter"
                                        "?force_room=_MAIL_&recp=");
@@ -216,7 +222,7 @@ void display_parsed_vcard(struct vCard *v, int full) {
                                strcat(mailto, "</A>");
                        }
                        else if (!strcasecmp(firsttoken, "tel")) {
-                               if (strlen(phone) > 0) strcat(phone, "<BR>");
+                               if (strlen(phone) > 0) strcat(phone, "<br />");
                                strcat(phone, thisvalue);
                                for (j=0; j<num_tokens(thisname, ';'); ++j) {
                                        extract_token(buf, thisname, j, ';');
@@ -242,7 +248,7 @@ void display_parsed_vcard(struct vCard *v, int full) {
                                                extract_token(buf, thisvalue, j, ';');
                                                if (strlen(buf) > 0) {
                                                        escputs(buf);
-                                                       wprintf("<BR>");
+                                                       wprintf("<br />");
                                                }
                                        }
                                        wprintf("</TD></TR>\n");
@@ -364,12 +370,13 @@ void read_message(long msgnum) {
        serv_printf("MSG4 %ld", msgnum);
        serv_gets(buf);
        if (buf[0] != '1') {
-               wprintf("<STRONG>ERROR:</STRONG> %s<BR>\n", &buf[4]);
+               wprintf("<STRONG>ERROR:</STRONG> %s<br />\n", &buf[4]);
                return;
        }
 
        /* begin everythingamundo table */
-       wprintf("<table width=100% border=1 cellspacing=0 "
+       wprintf("<div style=\"margin-right:1px\">\n");
+       wprintf("<table width=100%% border=1 cellspacing=0 "
                "cellpadding=0><TR><TD>\n");
 
        /* begin message header table */
@@ -381,7 +388,7 @@ void read_message(long msgnum) {
 
        while (serv_gets(buf), strcasecmp(buf, "text")) {
                if (!strcmp(buf, "000")) {
-                       wprintf("<I>unexpected end of message</I><BR><BR>\n");
+                       wprintf("<I>unexpected end of message</I><br /><br />\n");
                        wprintf("</SPAN>\n");
                        return;
                }
@@ -447,7 +454,7 @@ void read_message(long msgnum) {
                                        "TARGET=\"wc.%ld.%s\">"
                                        "<IMG SRC=\"/static/attachment.gif\" "
                                        "BORDER=0 ALIGN=MIDDLE>\n"
-                                       "Part %s: %s (%s, %d bytes)</A><BR>\n",
+                                       "Part %s: %s (%s, %d bytes)</A><br />\n",
                                        msgnum, mime_partnum,
                                        msgnum, mime_partnum,
                                        mime_partnum, mime_filename,
@@ -500,7 +507,7 @@ void read_message(long msgnum) {
 
        wprintf("</SPAN>");
        if (strlen(m_subject) > 0) {
-               wprintf("<BR>"
+               wprintf("<br />"
                        "<SPAN CLASS=\"message_subject\">"
                        "Subject: %s"
                        "</SPAN>", m_subject
@@ -514,7 +521,7 @@ void read_message(long msgnum) {
        wprintf("<INPUT TYPE=\"hidden\" NAME=\"msgid\" VALUE=\"%ld\">\n",
                msgnum);
        wprintf("<INPUT TYPE=\"hidden\" NAME=\"recp\" VALUE=\"");
-       urlescputs(reply_to);
+       escputs(reply_to);
        wprintf("\">\n");
 
        if (!strncasecmp(m_subject, "Re:", 2)) {
@@ -549,7 +556,7 @@ void read_message(long msgnum) {
        strcpy(mime_content_type, "text/plain");
        while (serv_gets(buf), (strlen(buf) > 0)) {
                if (!strcmp(buf, "000")) {
-                       wprintf("<I>unexpected end of message</I><BR><BR>\n");
+                       wprintf("<I>unexpected end of message</I><br /><br />\n");
                        goto ENDBODY;
                }
                if (!strncasecmp(buf, "Content-type: ", 14)) {
@@ -582,9 +589,9 @@ void read_message(long msgnum) {
                        wprintf("<TT>");
                        url(buf);
                        escputs(buf);
-                       wprintf("</TT><BR>\n");
+                       wprintf("</TT><br />\n");
                }
-               wprintf("</I><BR>");
+               wprintf("</I><br />");
        }
 
        else /* HTML is fun, but we've got to strip it first */
@@ -594,7 +601,7 @@ void read_message(long msgnum) {
 
        /* Unknown weirdness */
        else {
-               wprintf("I don't know how to display %s<BR>\n",
+               wprintf("I don't know how to display %s<br />\n",
                        mime_content_type);
                while (serv_gets(buf), strcmp(buf, "000")) { }
        }
@@ -642,7 +649,8 @@ ENDBODY:
        wprintf("</TD></TR></TABLE>\n");
 
        /* end everythingamundo table */
-       wprintf("</TD></TR></TABLE><BR>\n");
+       wprintf("</TD></TR></TABLE>\n");
+       wprintf("</div>\n");
 }
 
 
@@ -880,8 +888,8 @@ void fetch_ab_name(long msgnum, char *namebuf) {
  */
 int abcmp(const void *ab1, const void *ab2) {
        return(strcasecmp(
-               (((const struct addrbookent *)ab1)->ab_name),
-               (((const struct addrbookent *)ab2)->ab_name)
+               (((const struct addrbookent *)ab1)->ab_name),
+               (((const struct addrbookent *)ab2)->ab_name)
        ));
 }
 
@@ -950,7 +958,7 @@ void do_addrbook_view(struct addrbookent *addrbook, int num_ab) {
                        wprintf("</B>\n");
                }
        }
-       wprintf("<BR>\n");
+       wprintf("<br />\n");
 
        wprintf("<TABLE border=0 cellspacing=0 "
                "cellpadding=3 width=100%%>\n"
@@ -1000,7 +1008,7 @@ int load_msg_ptrs(char *servcmd)
        serv_puts(servcmd);
        serv_gets(buf);
        if (buf[0] != '1') {
-               wprintf("<EM>%s</EM><BR>\n", &buf[4]);
+               wprintf("<EM>%s</EM><br />\n", &buf[4]);
                return (nummsgs);
        }
        while (serv_gets(buf), strcmp(buf, "000")) {
@@ -1049,7 +1057,7 @@ void readloop(char *oper)
        is_summary = atoi(bstr("summary"));
        if (maxmsgs == 0) maxmsgs = DEFAULT_MAXMSGS;
 
-       output_headers(1);
+       output_headers(1, 1, 1, 0, 0, 0, 0);
 
        /* When in summary mode, always show ALL messages instead of just
         * new or old.  Otherwise, show what the user asked for.
@@ -1135,9 +1143,11 @@ void readloop(char *oper)
                }
        }
 
+       wprintf("<FORM NAME=\"msgomatic\" "
+               "METHOD=\"POST\" ACTION=\"/do_stuff_to_msgs\">\n");
        if (is_summary) {
-               wprintf("<FORM METHOD=\"POST\" ACTION=\"/do_stuff_to_msgs\">\n"
-                       "<TABLE border=0 cellspacing=0 "
+               wprintf("<div style=\"margin-right:1px\">"
+                       "<table border=0 cellspacing=0 "
                        "cellpadding=0 width=100%%>\n"
                        "<TR>"
                        "<TD><I>Subject</I></TD>"
@@ -1215,7 +1225,7 @@ void readloop(char *oper)
        }
 
        if (is_summary) {
-               wprintf("</TABLE>\n");
+               wprintf("</table></div>\n");
        }
 
        /* Bump these because although we're thinking in zero base, the user
@@ -1228,8 +1238,8 @@ void readloop(char *oper)
        if (num_displayed == 1) {
           if ((!is_tasks) && (!is_calendar) && (!is_addressbook) && (!is_notes) && (!is_singlecard)) {
 
-               wprintf("<CENTER>"
-                       "<TABLE BORDER=0 WIDTH=100%% BGCOLOR=\"#DDDDDD\"><TR><TD>"
+               wprintf("<div style=\"margin-right:1px\">"
+                       "<table border=0 width=100%% bgcolor=\"#dddddd\"><tr><td>"
                        "Reading #%d of %d messages.</TD>\n"
                        "<TD ALIGN=RIGHT><FONT SIZE=+1>",
                        lowest_displayed, nummsgs);
@@ -1266,7 +1276,7 @@ void readloop(char *oper)
                        oper,
                        WC->msgarr[0]);
 
-               wprintf("</TD></TR></TABLE></CENTER>\n");
+               wprintf("</td></tr></table></div>\n");
            }
        }
 
@@ -1275,55 +1285,53 @@ void readloop(char *oper)
         * messages, then display the selector bar
         */
        if (num_displayed > 1) {
-          if ((!is_tasks) && (!is_calendar) && (!is_addressbook) && (!is_notes) && (!is_singlecard)) {
-               wprintf("<CENTER>"
-                       "<TABLE BORDER=0 WIDTH=100%% BGCOLOR=\"#DDDDDD\"><TR><TD>"
-                       "Reading #%d-%d of %d messages.</TD>\n"
-                       "<TD ALIGN=RIGHT><FONT SIZE=+1>",
-                       lowest_displayed, highest_displayed, nummsgs);
+          if ((!is_tasks) && (!is_calendar) && (!is_addressbook)
+             && (!is_notes) && (!is_singlecard)) {
 
-               if (is_summary) {
-                       wprintf("<INPUT TYPE=\"submit\" NAME=\"sc\" "
-                               "VALUE=\"Delete selected\">\n");
-               }
+               wprintf("Reading #", lowest_displayed, highest_displayed);
 
+               wprintf("<SELECT NAME=\"whichones\" SIZE=\"1\" "
+                       "OnChange=\"location.href=msgomatic.whichones.options"
+                       "[selectedIndex].value\">\n");
 
                for (b=0; b<nummsgs; b = b + maxmsgs) {
                lo = b+1;
                hi = b+maxmsgs;
                if (hi > nummsgs) hi = nummsgs;
-                       if (WC->msgarr[b] != startmsg) {
-                               wprintf("<A HREF=\"/%s"
-                                       "?startmsg=%ld"
-                                       "&maxmsgs=%d"
-                                       "&summary=%d\">"
-                                       "%d-%d</A> \n",
-                                               oper,
-                                               WC->msgarr[b],
-                                               maxmsgs,
-                                               is_summary,
-                                               lo, hi);
-                       }
-                       else {
-                               wprintf("%d-%d \n", lo, hi);
-                       }
-
+                       wprintf("<OPTION %s VALUE="
+                               "\"/%s"
+                               "?startmsg=%ld"
+                               "&maxmsgs=%d"
+                               "&summary=%d\">"
+                               "%d-%d</OPTION> \n",
+                               ((WC->msgarr[b] == startmsg) ? "SELECTED" : ""),
+                               oper,
+                               WC->msgarr[b],
+                               maxmsgs,
+                               is_summary,
+                               lo, hi);
                }
-               wprintf("<A HREF=\"/%s?startmsg=%ld"
+               wprintf("<OPTION VALUE=\"/%s?startmsg=%ld"
                        "&maxmsgs=999999&summary=%d\">"
                        "ALL"
-                       "</A> ",
+                       "</OPTION> ",
                        oper,
                        WC->msgarr[0], is_summary);
 
-               wprintf("<A HREF=\"/%s?startmsg=%ld"
+               wprintf("<OPTION VALUE=\"/%s?startmsg=%ld"
                        "&maxmsgs=999999&summary=1\">"
                        "Summary"
-                       "</A>",
+                       "</OPTION>",
                        oper,
                        WC->msgarr[0]);
 
-               wprintf("</TD></TR></TABLE></CENTER>\n");
+               wprintf("</SELECT> of %d messages.", nummsgs);
+
+               if (is_summary) {
+                       wprintf("<INPUT TYPE=\"submit\" NAME=\"sc\" "
+                               "VALUE=\"Delete selected\">\n");
+               }
+
            }
        }
        if (is_summary) wprintf("</FORM>\n");
@@ -1488,8 +1496,12 @@ void post_message(void)
                serv_gets(buf);
                if (buf[0] == '4') {
                        post_mime_to_server();
-                       sprintf(WC->ImportantMessage, 
-                               "Message has been posted.\n");
+                       if (strlen(bstr("recp")) > 0) {
+                               sprintf(WC->ImportantMessage, "Message has been sent.\n");
+                       }
+                       else {
+                               sprintf(WC->ImportantMessage, "Message has been posted.\n");
+                       }
                        dont_post = atol(bstr("postseq"));
                } else {
                        sprintf(WC->ImportantMessage, 
@@ -1543,8 +1555,13 @@ void display_enter(void)
        }
 #endif
 
-       /* Otherwise proceed normally */
-       output_headers(1);
+       /* Otherwise proceed normally.  Do a custom room banner with no navbar... */
+       output_headers(1, 1, 2, 0, 0, 0, 0);
+       wprintf("<div id=\"banner\">\n");
+       embed_room_banner(NULL, navbar_none);
+       wprintf("</div>\n");
+       wprintf("<div id=\"content\">\n");
+
        sprintf(buf, "ENT0 0|%s|0|0", bstr("recp"));
        serv_puts(buf);
        serv_gets(buf);
@@ -1552,7 +1569,7 @@ void display_enter(void)
        if (!strncmp(buf, "570", 3)) {
                if (strlen(bstr("recp")) > 0) {
                        svprintf("RECPERROR", WCS_STRING,
-                               "<SPAN CLASS=\"errormsg\">%s</SPAN><BR>\n",
+                               "<SPAN CLASS=\"errormsg\">%s</SPAN><br />\n",
                                &buf[4]
                        );
                }
@@ -1560,7 +1577,7 @@ void display_enter(void)
                goto DONE;
        }
        if (buf[0] != '2') {
-               wprintf("<EM>%s</EM><BR>\n", &buf[4]);
+               wprintf("<EM>%s</EM><br />\n", &buf[4]);
                goto DONE;
        }
 
@@ -1574,42 +1591,46 @@ void display_enter(void)
        }
        strcat(&buf[strlen(buf)], " <I>in</I> ");
        stresc(&buf[strlen(buf)], WC->wc_roomname, 1, 1);
-       svprintf("BOXTITLE", WCS_STRING, buf);
-       do_template("beginbox");
 
-       wprintf("<CENTER>\n");
+       /* begin message entry screen */
+       wprintf("<div style=\"position:absolute; left:1%%; width:96%%; height:100%%\">\n");
 
-       wprintf("<FORM ENCTYPE=\"multipart/form-data\" "
-               "METHOD=\"POST\" ACTION=\"/post\" "
-               "NAME=\"enterform\""
+       wprintf("<form enctype=\"multipart/form-data\" "
+               "method=\"POST\" action=\"/post\" "
+               "name=\"enterform\""
                "onSubmit=\"return submitForm();\""
                ">\n");
-       wprintf("<INPUT TYPE=\"hidden\" NAME=\"recp\" VALUE=\"%s\">\n",
+       wprintf("<input type=\"hidden\" name=\"recp\" value=\"%s\">\n",
                bstr("recp"));
-       wprintf("<INPUT TYPE=\"hidden\" NAME=\"postseq\" VALUE=\"%ld\">\n",
+       wprintf("<input type=\"hidden\" name=\"postseq\" value=\"%ld\">\n",
                now);
 
-       wprintf("<TABLE border=0 cellspacing=0 cellpadding=0 width=100%%>\n");
-       wprintf("<TR><TD ALIGN=LEFT>");
-       wprintf("<IMG SRC=\"static/enter.gif\" ALIGN=MIDDLE ALT=\" \">");
+       wprintf("%s<br>\n", buf);       /* header bar */
+       wprintf("<img src=\"static/enter.gif\" align=middle alt=\" \">");
                /* "onLoad=\"document.enterform.msgtext.focus();\" " */
-       wprintf("<FONT SIZE=-1>Subject (optional):</FONT>"
-               "<INPUT TYPE=\"text\" NAME=\"subject\" VALUE=\"");
+       wprintf("<font size=-1>Subject (optional):</font>"
+               "<input type=\"text\" name=\"subject\" value=\"");
        escputs(bstr("subject"));
-       wprintf("\" SIZE=40 MAXLENGTH=70>"
+       wprintf("\" size=40 maxlength=70>"
                "&nbsp;"
        );
-       wprintf("</TD>");
 
-       wprintf("<TD ALIGN=RIGHT>");
-       wprintf("<INPUT TYPE=\"submit\" NAME=\"sc\" VALUE=\"Save message\">"
-               "&nbsp;"
-               "<INPUT TYPE=\"submit\" NAME=\"sc\" VALUE=\"Cancel\"><BR>\n");
-       wprintf("</TD></TR></TABLE>\n");
+       wprintf("<input type=\"submit\" name=\"sc\" value=\"");
+       if (strlen(bstr("recp")) > 0) {
+               wprintf("Send message");
+       } else {
+               wprintf("Post message");
+       }
+       wprintf("\">&nbsp;"
+               "<input type=\"submit\" name=\"sc\" value=\"Cancel\">\n");
 
-       wprintf("<SCRIPT language=\"JavaScript\" type=\"text/javascript\" "
-               "src=\"static/richtext_compressed.js\"></SCRIPT>\n"
-               "<SCRIPT language=\"JavaScript\" type=\"text/javascript\">\n"
+       /* begin richedit box */
+       wprintf("<div style=\"position:absolute; left:0%%; width:100%%; "
+               "top:15%; height:75%%\">\n");
+
+       wprintf("<script type=\"text/javascript\" "
+               "src=\"static/richtext.js\"></script>\n"
+               "<script type=\"text/javascript\">\n"
                "function submitForm() { \n"
                "  updateRTE('msgtext'); \n"
                "  return true; \n"
@@ -1617,39 +1638,42 @@ void display_enter(void)
                "  \n"
                "initRTE(\"static/\", \"static/\", \"\"); \n"
                "</script> \n"
-               "<noscript>JAVASCRIPT MUST BE ENABLED.</noscript> \n"
-               "<SCRIPT language=\"javascript\" type=\"text/javascript\"> \n"
+               "<noscript>JAVAscript MUST BE ENABLED.</noscript> \n"
+               "<script type=\"text/javascript\"> \n"
                "writeRichText('msgtext', '");
        msgescputs(bstr("msgtext"));
-       wprintf("', '100%%', 200, true, false); \n"
+       wprintf("', '100%%', '80%%', true, false); \n"
                "</script> \n");
+       wprintf("</div>\n");    /* end richedit box */
 
-/*
- * Before we had the richedit widget, we did it this way...
- *
-       wprintf("<TEXTAREA NAME=\"msgtext\" wrap=soft ROWS=25 COLS=80 "
-               "WIDTH=80>");
-       escputs(bstr("msgtext"));
-       wprintf("</TEXTAREA><BR>\n");
- */
+       /* Here comes the "do attachments" section on the bottom */
+       wprintf("<div style=\"position:absolute; bottom:0px; left:0px; width:100%%\">\n");
 
        /* Enumerate any attachments which are already in place... */
+       wprintf("<img src=\"/static/attachment.gif\" border=0 "
+               "align=middle height=16 width=16> Attachments: ");
+       wprintf("<select name=\"which_attachment\" size=1>");
        for (att = WC->first_attachment; att != NULL; att = att->next) {
-               wprintf("<IMG SRC=\"/static/attachment.gif\" "
-                       "BORDER=0 ALIGN=MIDDLE> Attachment: ");
+               wprintf("<option value=\"");
+               urlescputs(att->filename);
+               wprintf("\">");
                escputs(att->filename);
-               wprintf(" (%s, %d bytes)<BR>\n",
-                       att->content_type, att->length);
+               /* wprintf(" (%s, %d bytes)",att->content_type,att->length); */
+               wprintf("</option>\n");
        }
+       wprintf("</select>");
 
        /* Now offer the ability to attach additional files... */
        wprintf("&nbsp;&nbsp;&nbsp;"
                "Attach file: <input NAME=\"attachfile\" "
-               "SIZE=48 TYPE=\"file\">\n&nbsp;&nbsp;"
+               "SIZE=16 TYPE=\"file\">\n&nbsp;&nbsp;"
                "<input type=\"submit\" name=\"attach\" value=\"Add\">\n");
 
-       wprintf("</FORM></CENTER>\n");
-       do_template("endbox");
+       wprintf("</div>\n");    /* end attachments section */
+
+       wprintf("</FORM>\n");
+
+       wprintf("</div>\n");
 DONE:  wDumpContent(1);
 }
 
@@ -1667,12 +1691,12 @@ void delete_msg(void)
 
        msgid = atol(bstr("msgid"));
 
-       output_headers(1);
+       output_headers(1, 1, 1, 0, 0, 0, 0);
 
        sprintf(buf, "DELE %ld", msgid);
        serv_puts(buf);
        serv_gets(buf);
-       wprintf("<EM>%s</EM><BR>\n", &buf[4]);
+       wprintf("<EM>%s</EM><br />\n", &buf[4]);
 
        wDumpContent(1);
 }
@@ -1691,16 +1715,17 @@ void confirm_move_msg(void)
 
        msgid = atol(bstr("msgid"));
 
-       output_headers(1);
+       output_headers(1, 1, 1, 0, 0, 0, 0);
 
-       wprintf("<TABLE WIDTH=100%% BORDER=0 BGCOLOR=\"#444455\"><TR><TD>");
-       wprintf("<FONT SIZE=+1 COLOR=\"#FFFFFF\"");
-       wprintf("<B>Confirm move of message</B>\n");
-       wprintf("</FONT></TD></TR></TABLE>\n");
+       wprintf("<div style=\"margin-right:1px\">"
+               "<table width=100%% border=0 bgcolor=\"#444455\"><tr><td>");
+       wprintf("<font size=+1 color=\"#ffffff\"");
+       wprintf("<b>Confirm move of message</b>\n");
+       wprintf("</font></td></tr></table></div>\n");
 
        wprintf("<CENTER>");
 
-       wprintf("Move this message to:<BR>\n");
+       wprintf("Move this message to:<br />\n");
 
        wprintf("<FORM METHOD=\"POST\" ACTION=\"/move_msg\">\n");
        wprintf("<INPUT TYPE=\"hidden\" NAME=\"msgid\" VALUE=\"%s\">\n",
@@ -1719,7 +1744,7 @@ void confirm_move_msg(void)
                }
        }
        wprintf("</SELECT>\n");
-       wprintf("<BR>\n");
+       wprintf("<br />\n");
 
        wprintf("<INPUT TYPE=\"submit\" NAME=\"yesno\" VALUE=\"Move\">");
        wprintf("&nbsp;");
@@ -1739,15 +1764,15 @@ void move_msg(void)
 
        msgid = atol(bstr("msgid"));
 
-       output_headers(1);
+       output_headers(1, 1, 1, 0, 0, 0, 0);
 
        if (!strcasecmp(bstr("yesno"), "Move")) {
                sprintf(buf, "MOVE %ld|%s", msgid, bstr("target_room"));
                serv_puts(buf);
                serv_gets(buf);
-               wprintf("<EM>%s</EM><BR>\n", &buf[4]);
+               wprintf("<EM>%s</EM><br />\n", &buf[4]);
        } else {
-               wprintf("<EM>Message not moved.</EM><BR>\n");
+               wprintf("<EM>Message not moved.</EM><br />\n");
        }
 
        wDumpContent(1);