- else {
- wprintf("<EM>%s</EM><BR>\n", &buf[4]);
- }
- }
-
- if (!strcasecmp(closewin, "yes")) {
- wprintf("<CENTER><A HREF=\"javascript:window.close();\">"
- "[ close window ]</A></CENTER>\n");
- }
-
- wDumpContent(1);
-}
-
-
-
-/*
- * multiuser chat
- */
-void do_chat(void)
-{
- char buf[SIZ];
-
- /* First, check to make sure we're still allowed in this room. */
- serv_printf("GOTO %s", WC->wc_roomname);
- serv_gets(buf);
- if (buf[0] != '2') {
- smart_goto("_BASEROOM_");
- return;
- }
-
- /* If the chat socket is still open from a previous chat,
- * close it -- because it might be stale or in the wrong room.
- */
- if (WC->chat_sock < 0) {
- close(WC->chat_sock);
- WC->chat_sock = (-1);
- }
-
- /* Ok, we're good. Here we go. */
- output_headers(3);
-
- wprintf("<TABLE WIDTH=100%% BORDER=0 BGCOLOR=\"#000077\"><TR><TD>"
- "<SPAN CLASS=\"titlebar\">"
- "<IMG SRC=\"/static/chat-icon.gif\" WIDTH=16 HEIGHT=16 ALIGN=MIDDLE>"
- );
- escputs(WC->wc_roomname);
- wprintf(": real-time chat</SPAN>\n"
- "</TD></TR></TABLE>\n"
-
- "<IFRAME WIDTH=100%% HEIGHT=200 SRC=\"about:blank\" "
- "NAME=\"chat_transcript\">\n"
- "<!-- Alternate content for non-supporting browsers -->\n"
- "If you are seeing this message, your browser does not contain\n"
- "the IFRAME support required for the chat window. Please upgrade\n"
- "to a supported browser, such as\n"
- "<A HREF=\"http://www.mozilla.org\">Mozilla</A>.\n"
- "</IFRAME>\n"
-
- "<IFRAME WIDTH=100%% HEIGHT=1 SRC=\"/chat_recv\" "
- "NAME=\"chat_recv\">\n"
- "</IFRAME>"
-
- "<BR>\n"
-
- "<IFRAME WIDTH=100%% HEIGHT=60 SRC=\"/chat_send\" "
- "NAME=\"chat_send\">\n"
- "</IFRAME>\n"
- );
- wDumpContent(1);
-}
-
-
-/*
- *
- */
-void page_popup(void)
-{
- char buf[SIZ];
- char pagefrom[SIZ];
-
- /* suppress express message check, do headers but no frames */
- output_headers(0x08 | 0x03);
-
- while (serv_puts("GEXP"), serv_gets(buf), buf[0]=='1') {
-
- extract(pagefrom, &buf[4], 3);
-
- wprintf("<TABLE WIDTH=100%% BORDER=0 BGCOLOR=\"#007700\"><TR><TD>");
- wprintf("<SPAN CLASS=\"titlebar\">Instant message from ");
- escputs(pagefrom);
- wprintf("</SPAN></TD></TR></TABLE>\n");
-
- fmout(NULL, "LEFT");