Patch for html version of INN status file
Yury B.Razbegin
yur at simtel.ru
Fri Nov 17 15:08:19 UTC 2000
Hi !
I suggest patch for INN-2.3.1 (STABLE) for possibility of adjustment by
the user of appearance of HTML-file of status INN by possibility of inclusion
of heading "header.html" file. This patch eliminates also absence of background
color in the resulting HTML-file of status INN.
The result of operation INN with the imposed patch can be looked here:
http://newsfeed.simtel.ru/InnReport/inn_status.html
--
* Yury B.Razbegin * yur at simtel.ru * +7 (-8422) -35-32-09 (Fax: -41-00-19) *
==== Patch follows ================================================================
*** innd/status.c.orig Wed Sep 20 13:03:09 2000
--- innd/status.c Fri Nov 17 16:45:42 2000
***************
*** 9,15 ****
#define MIN_REFRESH 60 /* 1 min */
#define HTML_STATUS
#if defined(HTML_STATUS)
! #define STATUS_FILE "inn_status.html" /* will be in pathhttp */
#else
#define STATUS_FILE "inn.status" /* will be in pathlog */
#endif
--- 9,17 ----
#define MIN_REFRESH 60 /* 1 min */
#define HTML_STATUS
#if defined(HTML_STATUS)
! #define STATUS_FILE "inn_status.html" /* will be in pathhttp */
! #define STATUS_HEADER_FILE "header.html" /* will be in pathhttp */
! char *HTML_Header = NULL;
#else
#define STATUS_FILE "inn.status" /* will be in pathlog */
#endif
***************
*** 121,131 ****
#if defined(HTML_STATUS)
/* HTML Header */
-
fprintf (F,"<HTML>\n<HEAD>\n<META HTTP-EQUIV=\"Refresh\" CONTENT=\"%d;\">\n",
! innconf->status < MIN_REFRESH ? MIN_REFRESH : innconf->status);
! fprintf (F, "<TITLE>%s: incoming feeds</TITLE>\n", innconf->pathhost);
! fprintf (F, "</HEAD>\n<BODY>\n<PRE>\n") ;
#endif /* defined(HTML_STATUS) */
fprintf (F, "%s\n", inn_version_string);
--- 123,143 ----
#if defined(HTML_STATUS)
/* HTML Header */
fprintf (F,"<HTML>\n<HEAD>\n<META HTTP-EQUIV=\"Refresh\" CONTENT=\"%d;\">\n",
! innconf->status < MIN_REFRESH ? MIN_REFRESH : innconf->status);
! fprintf (F, "<TITLE>%s: incoming feeds</TITLE>\n</HEAD>\n",
! innconf->pathhost);
! if (HTML_Header == NULL) {
! sprintf (TempString, "%s/%s", innconf->pathhttp, STATUS_HEADER_FILE);
! if (HTML_Header = ReadInFile(TempString, NULL))
! goto Write_HTML_Header;
! fputs ("<BODY BGCOLOR=\"F0F0F0\" TEXT=\"#000000\">\n", F);
! }
! else {
! Write_HTML_Header:
! fputs(HTML_Header, F);
! }
! fputs("<PRE>\n", F) ;
#endif /* defined(HTML_STATUS) */
fprintf (F, "%s\n", inn_version_string);
More information about the inn-bugs
mailing list