Updates for html sitedocs
This commit is contained in:
parent
0b9ee8edc8
commit
fb6348bd38
1
TODO
1
TODO
@ -170,7 +170,6 @@ mbsetup:
|
||||
N: When a message area is deleted, delete the rulesfile too.
|
||||
|
||||
X: Generate crossreference document:
|
||||
Filefind flags <=> TIC Areas
|
||||
Fileechos <=> Groups
|
||||
Fileechos <=> Magic processing
|
||||
Fileechos <=> Hatch
|
||||
|
@ -103,7 +103,7 @@ m_ff.o: ../config.h ../lib/mbselib.h screen.h mutil.h ledit.h stlist.h m_global.
|
||||
m_hatch.o: ../config.h ../lib/mbselib.h screen.h mutil.h ledit.h stlist.h m_global.h m_fgroup.h m_ticarea.h m_hatch.h
|
||||
m_mail.o: ../config.h ../lib/mbselib.h screen.h mutil.h ledit.h m_global.h m_marea.h m_mgroup.h m_mail.h
|
||||
m_modem.o: ../config.h ../lib/mbselib.h screen.h mutil.h ledit.h stlist.h m_global.h m_modem.h
|
||||
m_ol.o: ../config.h ../lib/mbselib.h screen.h mutil.h ledit.h m_global.h m_ol.h
|
||||
m_ol.o: ../config.h ../lib/mbselib.h ../lib/diesel.h screen.h mutil.h ledit.h m_global.h m_ol.h
|
||||
m_tic.o: ../config.h ../lib/mbselib.h screen.h mutil.h ledit.h m_fgroup.h m_ticarea.h m_magic.h m_hatch.h m_tic.h
|
||||
m_virus.o: ../config.h ../lib/mbselib.h ../paths.h screen.h mutil.h ledit.h stlist.h m_global.h m_virus.h
|
||||
stlist.o: ../config.h ../lib/mbselib.h stlist.h
|
||||
|
@ -96,9 +96,13 @@ int bbs_doc(FILE *fp, FILE *toc, int page)
|
||||
addtoc(fp, toc, 8, 0, page, (char *)"BBS setup");
|
||||
|
||||
page = bbs_limits_doc(fp, toc, page);
|
||||
dotter();
|
||||
page = bbs_lang_doc(fp, toc, page);
|
||||
dotter();
|
||||
page = bbs_menu_doc(fp, toc, page);
|
||||
dotter();
|
||||
page = bbs_file_doc(fp, toc, page);
|
||||
dotter();
|
||||
page = bbs_prot_doc(fp, toc, page);
|
||||
|
||||
return page;
|
||||
|
@ -433,8 +433,8 @@ void InitFilefind(void)
|
||||
int ff_doc(FILE *fp, FILE *toc, int page)
|
||||
{
|
||||
char temp[PATH_MAX];
|
||||
FILE *wp, *ip, *no;
|
||||
int i = 0, j;
|
||||
FILE *ti, *wp, *ip, *no;
|
||||
int refs, nr, i = 0, j;
|
||||
|
||||
sprintf(temp, "%s/etc/scanmgr.data", getenv("MBSE_ROOT"));
|
||||
if ((no = fopen(temp, "r")) == NULL)
|
||||
@ -482,6 +482,35 @@ int ff_doc(FILE *fp, FILE *toc, int page)
|
||||
add_webdigit(wp, (char *)"Keyword length", scanmgr.keywordlen);
|
||||
fprintf(wp, "</TBODY>\n");
|
||||
fprintf(wp, "</TABLE>\n");
|
||||
|
||||
fprintf(wp, "<HR>\n");
|
||||
fprintf(wp, "<H3>BBS File Areas Reference</H3>\n");
|
||||
nr = refs = 0;
|
||||
sprintf(temp, "%s/etc/fareas.data", getenv("MBSE_ROOT"));
|
||||
if ((ti = fopen(temp, "r"))) {
|
||||
fread(&areahdr, sizeof(areahdr), 1, ti);
|
||||
while ((fread(&area, areahdr.recsize, 1, ti)) == 1) {
|
||||
nr++;
|
||||
if (area.Available) {
|
||||
if (refs == 0) {
|
||||
fprintf(wp, "<TABLE width='600' border='0' cellspacing='0' cellpadding='2'>\n");
|
||||
fprintf(wp, "<COL width='15%%'><COL width='15%%'><COL width='70%%'>\n");
|
||||
fprintf(wp, "<TBODY>\n");
|
||||
fprintf(wp, "<TR><TH align='left'>Area</TH><TH align='left'>Search</TH><TH align='left'>Description</TH></TD>\n");
|
||||
}
|
||||
fprintf(wp, "<TR><TD><A HREF=\"filearea_%d.html\">Area %d</A></TD><TD>%s</TD><TD>%s</TD></TR>\n",
|
||||
nr, nr, getboolean(area.FileFind), area.Name);
|
||||
refs++;
|
||||
}
|
||||
}
|
||||
fclose(ti);
|
||||
}
|
||||
if (refs == 0)
|
||||
fprintf(wp, "No BBS File Areas References\n");
|
||||
else {
|
||||
fprintf(wp, "</TBODY>\n");
|
||||
fprintf(wp, "</TABLE>\n");
|
||||
}
|
||||
close_webdoc(wp);
|
||||
}
|
||||
|
||||
|
@ -80,6 +80,7 @@ int mail_doc(FILE *fp, FILE *toc, int page)
|
||||
addtoc(fp, toc, 9, 0, page, (char *)"Mail setup");
|
||||
|
||||
page = mail_group_doc(fp, toc, page);
|
||||
dotter();
|
||||
page = mail_area_doc(fp, toc, page);
|
||||
|
||||
return page;
|
||||
|
@ -1422,7 +1422,7 @@ int node_doc(FILE *fp, FILE *toc, int page)
|
||||
|
||||
sprintf(temp, "node_%d_%d_%d_%d_%s.html", nodes.Aka[0].zone, nodes.Aka[0].net, nodes.Aka[0].node,
|
||||
nodes.Aka[0].point, nodes.Aka[0].domain);
|
||||
fprintf(ip, " <LI><A HREF=\"%s\">Node %s</A> %s</LI>\n", temp, aka2str(nodes.Aka[0]), nodes.Sysop);
|
||||
fprintf(ip, " <LI><A HREF=\"%s\">%s</A> %s</LI>\n", temp, aka2str(nodes.Aka[0]), nodes.Sysop);
|
||||
if ((wp = open_webdoc(temp, (char *)"Fidonet node", aka2str(nodes.Aka[0])))) {
|
||||
fprintf(wp, "<A HREF=\"index.html\">Main</A> <A HREF=\"nodes.html\">Back</A>\n");
|
||||
fprintf(wp, "<P>\n");
|
||||
|
@ -30,6 +30,7 @@
|
||||
|
||||
#include "../config.h"
|
||||
#include "../lib/mbselib.h"
|
||||
#include "../lib/diesel.h"
|
||||
#include "screen.h"
|
||||
#include "mutil.h"
|
||||
#include "ledit.h"
|
||||
@ -577,3 +578,35 @@ void ol_menu(void)
|
||||
}
|
||||
|
||||
|
||||
|
||||
void ol_doc(void)
|
||||
{
|
||||
FILE *fp, *wp;
|
||||
char *temp, out[1024];
|
||||
int nr = 0;
|
||||
|
||||
temp = calloc(PATH_MAX, sizeof(char));
|
||||
sprintf(temp, "%s/etc/oneline.data", getenv("MBSE_ROOT"));
|
||||
if ((fp = fopen(temp, "r"))) {
|
||||
if ((wp = open_webdoc((char *)"oneliners.html", (char *)"Oneliners", NULL))) {
|
||||
fprintf(wp, "<A HREF=\"index.html\">Main</A>\n");
|
||||
fprintf(wp, "<P>\n");
|
||||
fprintf(wp, "<TABLE border='1' cellspacing='0' cellpadding='2'>\n");
|
||||
fprintf(wp, "<TBODY>\n");
|
||||
fread(&olhdr, sizeof(olhdr), 1, fp);
|
||||
while (fread(&ol, olhdr.recsize, 1, fp) == 1) {
|
||||
nr++;
|
||||
html_massage(ol.Oneline, out);
|
||||
fprintf(wp, "<TR><TD>%d</TD><TD>%s</TD><TD>%s</TD><TD>%s</TD><TD>%s</TD></TR>\n",
|
||||
nr, out, ol.UserName, ol.DateOfEntry, getboolean(ol.Available));
|
||||
}
|
||||
fprintf(wp, "</TBODY>\n");
|
||||
fprintf(wp, "</TABLE>\n");
|
||||
close_webdoc(wp);
|
||||
}
|
||||
fclose(fp);
|
||||
}
|
||||
free(temp);
|
||||
}
|
||||
|
||||
|
||||
|
@ -8,6 +8,7 @@ int CountOneline(void);
|
||||
void EditOneline(void);
|
||||
void InitOneline(void);
|
||||
void ol_menu(void);
|
||||
void ol_doc(void);
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -69,6 +69,7 @@
|
||||
mode_t oldmask; /* Old umask value */
|
||||
extern int do_quiet; /* Suppress log to screen */
|
||||
extern int bbs_free; /* Free/Busy status */
|
||||
extern int horiz; /* Dot position in docs */
|
||||
int exp_golded = FALSE; /* Export GoldED config */
|
||||
int init = FALSE; /* Run init only */
|
||||
|
||||
@ -184,17 +185,6 @@ void soft_info(void)
|
||||
}
|
||||
|
||||
|
||||
int horiz;
|
||||
|
||||
void dotter(void);
|
||||
void dotter(void)
|
||||
{
|
||||
Nopper();
|
||||
mvprintw(8, horiz++, (char *)".");
|
||||
fflush(stdout);
|
||||
}
|
||||
|
||||
|
||||
|
||||
void site_docs(void);
|
||||
void site_docs(void)
|
||||
@ -301,6 +291,8 @@ void site_docs(void)
|
||||
page = task_doc(fp, toc, page);
|
||||
dotter();
|
||||
page = route_doc(fp, toc, page);
|
||||
dotter();
|
||||
ol_doc();
|
||||
clrtoeol();
|
||||
mvprintw( 8,11, (char *)"Created site documents in %s/doc", getenv("MBSE_ROOT"));
|
||||
fflush(stdout);
|
||||
|
@ -261,3 +261,13 @@ void add_statcnt(FILE *fp, char * hstr, statcnt st)
|
||||
}
|
||||
|
||||
|
||||
|
||||
int horiz;
|
||||
|
||||
void dotter(void)
|
||||
{
|
||||
Nopper();
|
||||
mvprintw(8, horiz++, (char *)".");
|
||||
fflush(stdout);
|
||||
}
|
||||
|
||||
|
@ -14,5 +14,6 @@ void add_webtable(FILE *, char *, char *);
|
||||
void add_webdigit(FILE *, char *, int);
|
||||
void add_colors(FILE *, char *, int, int);
|
||||
void add_statcnt(FILE *, char *, statcnt);
|
||||
void dotter(void);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user