From 585ca9d3efb80639e56e31abbdf97910f06ff847 Mon Sep 17 00:00:00 2001 From: Stefan Ritt Date: Thu, 3 Apr 2003 08:08:50 +0000 Subject: [PATCH] Added option 'Summary page title' SVN revision: 467 --- doc/ChangeLog | 5 +++++ doc/config.html | 7 +++++++ src/elogd.c | 29 +++++++++++++++++++++-------- 3 files changed, 33 insertions(+), 8 deletions(-) diff --git a/doc/ChangeLog b/doc/ChangeLog index f06ea085..97526429 100755 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -1,3 +1,8 @@ +Version 2.3.5, released April xxx, 2003 +======================================= + +- Added option "Summary page title" + Version 2.3.4, released April 2nd, 2003 ======================================= diff --git a/doc/config.html b/doc/config.html index 44e3df50..c11d1e55 100755 --- a/doc/config.html +++ b/doc/config.html @@ -169,6 +169,13 @@ from each message. The option Page title in the [gl section is used for the logbook selection page.

+

  • Summary page title = <string> +
    +The same for the summary or find result page. This may include substitutions as well, although +attribute substitutions make no sense here, since the summary page may contain many messages +with different attributes. +

    +

  • Selection page = <file>
    When this option is present, a user defined file is displayed instead of the logbook diff --git a/src/elogd.c b/src/elogd.c index 9ae729d1..afd943ff 100755 --- a/src/elogd.c +++ b/src/elogd.c @@ -6,6 +6,9 @@ Contents: Web server program for Electronic Logbook ELOG $Log$ + Revision 1.64 2003/04/03 08:08:50 midas + Added option 'Summary page title' + Revision 1.63 2003/04/02 08:11:49 midas Fixed bug with missing link in reply/upload @@ -4628,14 +4631,16 @@ time_t now; struct tm *ts; /* copy attribute list */ - for (i=0 ; in_attr ; i++) - { - strcpy(list[i], attr_list[i]); - if (attrib) - strcpy(value[i], attrib[i]); - else - strcpy(value[i], getparam(attr_list[i])); - } + i = 0; + if (attrib != NULL) + for (; in_attr ; i++) + { + strcpy(list[i], attr_list[i]); + if (attrib) + strcpy(value[i], attrib[i]); + else + strcpy(value[i], getparam(attr_list[i])); + } /* add remote host */ strcpy(list[i], "remote_host"); @@ -8454,6 +8459,14 @@ LOGBOOK *lbs_cur; /*---- header ----*/ + if (getcfg(lbs->name, "Summary Page Title", str)) + { + i = build_subst_list(lbs, slist, svalue, NULL); + strsubst(str, slist, svalue, i); + } + else + strcpy(str, "ELOG"); + sprintf(str, "ELOG %s", lbs->name); show_standard_header(lbs, TRUE, str, NULL);