diff --git a/doc/config.html b/doc/config.html index ab713703..ba27c031 100755 --- a/doc/config.html +++ b/doc/config.html @@ -1,50 +1,58 @@ - -
--
--
--
-The configuration file elogd.cfg contains entries which define
-the structure of logbooks and the behaviour of elogd. The file has a simple ASCII
-format. Each logbook is defined by a [<name>] section
-where <name> is the name of the logbook. The [global]
-section is used for settings common to all logbooks. Each line contains a setting
-name, followed by an equal sign and the value for this setting. Lines starting with
-";" are treated as comments.
-
-Here is a simple example, which define two logbooks, "Linux" and "PC": -
-
+ + + + ++ ELOG - Syntax of elogd.cfg + + + + + + + + ++ ELOG - Syntax of elogd.cfg +
+
+
++ Global and individual logbook options for an ELOG server ++
++ The configuration file
+elogd.cfgcontains entries + which define the structure of logbooks and the behaviour of +elogd. The file has a simple ASCII format. Each + logbook is defined by a[<name>]section where + <name> is the name of the logbook. The[global]+ section is used for settings common to all logbooks. Each line contains a + setting name, followed by an equal sign and the value for this setting. + Lines starting with ";" are treated as comments. ++ Here is a simple example, which define two logbooks, "Linux" and + "PC": +
+
[global] SMTP host = mailsend.your.domain @@ -65,276 +73,363 @@ Options OS = Linux, Windows ME, Windows 2000 Required Attributes = Location, Owner Email All = name@address, othername@otheraddress Use Mail Subject = Location -
-
-
-The notation of the following options is such that items enclosed by "<" and ">"
-should be replaced by a specific string. If a value contains blanks (like a complete sentence), it
-should not be enclosed in quotation marks.
-
-If a setting has a number of possible options, they are shown in the form
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ The notation of the following options is such that items enclosed by
+ "<" and ">" should be replaced by a specific string.
+ If a value contains blanks (like a complete sentence), it should
+ not be enclosed in quotation marks.
+
+ If a setting has a number of possible options, they are shown in the form
+
-
-
-
-
-
-
-
-
-
-then the URL under which
-
-
-
-
-
-
-
-If installations have very many logbooks, it can be hard to navigate between them.
-To make things more structured, it is possible to build a hierarchy of logbooks. A
-logbook group can contain any number of logbooks as well as other logbook groups.
-The hierarchy is defined with the the option
-
-
-
-in the
-
-To define following logbook hierarchy:
-
-
-
-one would use following statements:
-
-
+ then the URL under which
-option1|option2|..., meaning that one of the options (without any vertical bar)
-should be used.
-
-The following options are specific to the [global] section:
-
-
-
+
+ Port = <port>
-
-Specifies the TCP port under which the server is listening. Default is 80. Can be superseeded
-via the '-p' command line flag.
-Resource dir = <directory>
-
-Specifies the root directory for ELOG resources like help files, themes, icons and user HTML
-files. Can be overwritten with the -s flag when starting elogd. If not
-specified, use the directory where the configuration file elogd.cfg resides.
-Changing this option requires a restart of the elogd server.
-Logbook dir = <directory>
-
-Specifies the root directory for logbooks. Can be overwritten with the -d flag when
-starting elogd. If not specified, use the directory where the configuration file elogd.cfg
- resides. Each logbook data is stored in a separate directory under this root directory
-specified by the Subdir option.
-Changing this option requires a restart of the elogd server.
-Language = <name>
-
-
-The language setting determines the language of the elogd output. Not
-affected by this setting are the configuration file options and the commands specified with the
-optional Menu commands and List menu commands, which
-have to be specified in English and are translated automatically by elogd. The attribute names
-are unaffected by the language setting and have to be translated manually.
-
-If a language name is given (currently "german", "french", "spanish",
-"dutch", "brazilian" are supported out-of-the-box),
-the system searches for a file named eloglang.<name> containing
-string translations from English into that language. If you create a new translation file,
-please send it back to the author to be included in future distributions.
-
-
-The online help for elogd is contained in the file eloghelp_xx.html where
-xx are the first two letters of the language (like "en", "ge" and "fr"). For new languages, a new file of that type must be created as well.
-charset = <name>
-
-Specifies the charset of the pages produced by elogd. Can be used to switch to
-Russian or Asian fonts.
-Logbook Tabs = [0|1]
-
-This flag controls the display of "tabs" on top of the logbook page which
-allow to quickly switch between logbooks. Default is 1
-Main Tab = <string>
-
-If this option is present, an additional first tab is displayed which takes you back
-to the main logbook selection page. The string is used for the
-contents of the tab.
-Welcome Title = <html code>
-
-This optional HTML code gets displayed in the title of the logbook selection
-page. It can contain images via <img src="welcome.gif">.
-These images must be stored in the resource directory or in the theme directory.
-
-
-The following line is an example Welcome Title:
-
-Welcome title = <img src="welcome.jpg"><p><font size=5 color=white>Welcome to our Elog</font>
-
-This displays an image and a text below.
-Page title = <string>
-
-The string specified here is used for the title of individual logbook pages. It is also
-used by most browsers for bookmark names. <string> can contain substitutions
-like $<attribute> where <attribute> gets replaced by the attribute string
-from each message. The option Page title in the [global]
-section is used for the logbook selection page.
-List 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
-selection page. This file must be stored in the resource directory. Alternatively, an
-absolute path can be used if the file name starts with a
-"/" (Unix) or "\" or "x:"
-(Windows).
-
-It can be completely customized in order to contain logos etc. As a template,
-the standard selection page produced by elogd can be used.
-Guest Selection page = <file>
-
-The same for installations which have a global password file. This means that the
-logbook selection page is also password protected. It might be however that some
-logbooks have guest access, in which case guest access to the selection page should
-be allowed as well (maybe with only a subset of the available logbooks). In that case
-this options can be used, to show a list of logbooks with guest access.
-Protect Selection page = 0 | 1
-
-Normally, one can see the logbook selection page without having to log in. If one
-wants to require a login for the selection page, this switch can be set to
-1. Default is 0. It is necessary to put the
-Password file = ... into the [global] section of the
-config file for this to work.Expand Selection page = 0 | 1
-
-If this option is not present or set to one, the logbook selection page is expanded
-(all logbooks are shown if groups of logbooks are present). If this option is zero,
-only the group names are displayed. If one clicks on a group, its logbooks are shown.
-Using this option set to zero only makes sense if one has a large number of logbooks
-which would not fit on a single browser window, so collapsing makes sense.
-Default is 1.SMTP host = <host.domain>
-
-This defines the SMTP host needed to send automatic email notifications. The host
-name you can get from your email program or your local system administrator.
-SMTP username = <username>
-
-Some SMTP server require username/passowrd authentication. This option specifies
-the SMTP user name, while the option SMTP password can be created
-or modified via the -t switch when starting elogd. This is
-necessary since the password is encrypted. To set your SMPT password, enter on
-the command line:
-
-
+
+
+ option1|option2|..., meaning that one of the options
+ (without any vertical bar) should be used. The following options are
+ specific to the [global] section:
+
+
-
-Port = <port>
+ Specifies the TCP port under which the server is listening. Default is
+ 80. Can be superseeded via the '-p' command line flag.
+ Resource dir = <directory>
+ Specifies the root directory for ELOG resources like help files,
+ themes, icons and user HTML files. Can be overwritten with the
+ -s flag when starting elogd. If not specified, use
+ the directory where the configuration file
+ elogd.cfg resides. Changing this option requires
+ a restart of the elogd server.
+ Logbook dir = <directory>
+ Specifies the root directory for logbooks. Can be overwritten with the
+ -d flag when starting elogd. If not specified, use
+ the directory where the configuration file
+ elogd.cfg resides. Each logbook data is stored in a
+ separate directory under this root directory specified by the
+ Subdir option. Changing this option requires a
+ restart of the elogd server.
+ Language = <name>
+ The language setting determines the language of the
+ elogd output. Not affected by this setting are the
+ configuration file options and the commands specified with the optional
+ Menu commands and List menu
+ commands, which have to be specified in English and are
+ translated automatically by elogd. The attribute names are unaffected
+ by the language setting and have to be translated manually.
+
+ If a language name is given (currently "german",
+ "french", "spanish", "dutch", "brazilian"
+ are supported out-of-the-box), the system searches for a file named
+ eloglang.<name> containing string translations from
+ English into that language. If you create a new translation file,
+ please send it back to the author to be included in future
+ distributions.
+
+ The online help for elogd is contained in the file
+ eloghelp_xx.html where xx are the first two
+ letters of the language (like "en", "ge" and
+ "fr"). For new languages, a new file of that type must be
+ created as well.
+ charset = <name>
+ Specifies the charset of the pages produced by
+ elogd. Can be used to switch to Russian or Asian
+ fonts.
+ Logbook Tabs = [0|1]
+ This flag controls the display of "tabs" on top of the logbook
+ page which allow to quickly switch between logbooks. Default is
+ 1
+ Main Tab = <string>
+ If this option is present, an additional first tab is displayed which
+ takes you back to the main logbook selection page. The
+ string is used for the contents of the tab.
+ Welcome Title = <html code>
+ This optional HTML code gets displayed in the title of the logbook
+ selection page. It can contain images via <img
+ src="welcome.gif">. These images must be stored in the
+ resource directory or in the theme directory.
+
+ The following line is an example Welcome Title:
+
+
+Welcome title = <img src="welcome.jpg"><p><font size=5 color=white>Welcome to our Elog</font>
+
+ This displays an image and a text below.
+ Page title = <string>
+ The string specified here is used for the title of individual logbook
+ pages. It is also used by most browsers for bookmark names.
+ <string> can contain substitutions like $<attribute> where
+ <attribute> gets replaced by the attribute string from each
+ message. The option Page title in the
+ [global] section is used for the logbook selection
+ page.
+ List 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 selection page. This file must be stored in the resource
+ directory. Alternatively, an absolute path can be used if the file name
+ starts with a "/" (Unix) or "\"
+ or "x:" (Windows).
+
+ It can be completely customized in order to contain logos etc. As a
+ template, the standard selection page produced by
+ elogd can be used.
+ Guest Selection page = <file>
+ The same for installations which have a global password file. This
+ means that the logbook selection page is also password protected. It
+ might be however that some logbooks have guest access, in which case
+ guest access to the selection page should be allowed as well (maybe
+ with only a subset of the available logbooks). In that case this
+ options can be used, to show a list of logbooks with guest access.
+ Protect Selection page = 0 | 1
+ Normally, one can see the logbook selection page without having to log
+ in. If one wants to require a login for the selection page, this switch
+ can be set to 1. Default is 0.
+ It is necessary to put the Password file = ... into
+ the [global] section of the config file for this to work.
+ Expand Selection page = 0 | 1
+ If this option is not present or set to one, the logbook selection page
+ is expanded (all logbooks are shown if groups of logbooks are present).
+ If this option is zero, only the group names are displayed. If one
+ clicks on a group, its logbooks are shown. Using this option set to
+ zero only makes sense if one has a large number of logbooks which would
+ not fit on a single browser window, so collapsing makes sense. Default
+ is 1.
+ SMTP host = <host.domain>
+ This defines the SMTP host needed to send automatic email
+ notifications. The host name you can get from your email program or
+ your local system administrator.
+ SMTP username = <username>
+ Some SMTP server require username/passowrd authentication. This option
+ specifies the SMTP user name, while the option SMTP
+ password can be created or modified via the
+ -t switch when starting elogd. This is necessary
+ since the password is encrypted. To set your SMPT password, enter on
+ the command line:
+
elogd -t <your password>
-Logfile = <file>
-
-This option specifies a filename which logs all login/logout activities and
-successful user connections for logbooks with user level access. The the
-logging level (see below) is larger than 1, also read and write accesses
-can be logged.Logging level = 1 | 2 | 3
-
-Specifies the logging level. The higher this value, the more information
-is logged. Default is 2:
-
-URL = <http[s]://host.domain[:port]/[subdir/]>
-
-If one of the three cases is true:
-
elogd runs with stunnel
-elogd runs under a proxy
-elogd is running has to be specified
-manually with this statement. The URL has to
-contain the port number if not the standard port 80 is used, it has to specify https://
-if used under stunnel, and it has to contain the directory if used under a proxy like
-
-
-
-
-URL = http://host.domain:8080/ if running on port 8080
-URL = https://host.domain/ if running under stunnel
-URL = http://host.domain/subdir/ if running under a proxy Usr = <name>
-Grp = <name>
-
-The user and group to run the elogd daemon under when started by root.Resolve host names = 0|1
-
-Resolve remote host names if set to 1. If set to 0, which is the
-default, only IP numbers are stored in any log file. If the hosts allow/deny
-options are used with host names, this setting must be set to 1. If turned
-on, the DNS server is contacted on each HTTP request to elog, which can slow down
-the server considerably for slow DNS servers.
-
-Group <group name> = <Logbook1>, <Logbook2>, <other group>[global] section of the configuration file.
+
+
Logfile = <file>
+ This option specifies a filename which logs all login/logout activities
+ and successful user connections for logbooks with user level access.
+ The the logging level (see below) is larger than 1,
+ also read and write accesses can be logged.
+ Logging level = 1 | 2 | 3
+ Specifies the logging level. The higher this value, the more
+ information is logged. Default is 2:
+
+
+ URL =
+ <http[s]://host.domain[:port]/[subdir/]>
+ If one of the three cases is true:
+
+
+ elogd runs with stunnel
+ elogd runs under a proxy
+ elogd is running has to
+ be specified manually with this statement. The URL has to contain the
+ port number if not the standard port 80 is used, it has to specify
+ https:// if used under stunnel, and it has to contain
+ the directory if used under a proxy like
+
+
+
+ This URL is then used for any redirection. For example if one submits a
+ new entry, the URL in the browser reads
+ ...<logbook>/?cmd=Submit&..., containing all the attributes
+ etc. After the submit this page gets redirected to
+ ...<logbook>/<ID>, where <ID> is the ID of the
+ new entry. For the redirection via the HTTP "Location:" statement, an
+ absolute URL is required. Since elogd cannot figure out the complete
+ URL under which it is running when accessed through an Apache proxy, this
+ statement is necessary to tell elogd the complete URL.
+
+
+
+
+ URL = http://host.domain:8080/
+
+ if running on port 8080
+
+
+
+
+
+ URL = https://host.domain/
+
+ if running under stunnel
+
+
+
+
+
+ URL = http://host.domain/subdir/
+
+ if running under a proxy
+
+ Relative redirection = 0|1
+ Under some circumstances, absolute redirection via a complete URL may
+ not work. If you access elogd through two different ways simulataneously,
+ for example directly and via a stunnel connection, a single absolute
+ URL cannot be used, because one connection starts with http://, and the
+ other with https://. Another case is when the elogd server has
+ a dynamic IP address, which changes from time to time. Setting
+ Relative redirection = 1,
+ relative redirection is used. This uses the current URL from the browser,
+ whatever it is, and only specifies the last part of the URL. It should
+ noted however that relative redirections are not allowed in the HTTP
+ standard, but most browsers support it anyhow. Problems have been reported
+ with the Safari browser. So this option should only be used when it is
+ really needed.
+ Usr = <name>
+ Grp = <name>
+ The user and group to run the elogd daemon under when started by root.
+ Resolve host names = 0|1
+ Resolve remote host names if set to 1. If set to 0, which
+ is the default, only IP numbers are stored in any log file. If the
+ hosts allow/deny options are used with host names,
+ this setting must be set to 1. If turned on, the DNS server is
+ contacted on each HTTP request to elog, which can slow down the server
+ considerably for slow DNS servers.
+
+
+
+ If installations have very many logbooks, it can be hard to navigate + between them. To make things more structured, it is possible to build a + hierarchy of logbooks. A logbook group can contain any number of logbooks + as well as other logbook groups. The hierarchy is defined with the the + option +
+
+ Group <group name> = <Logbook1>, <Logbook2>,
+ <other group>
+
+ in the [global] section of the configuration file.
+
+ To define following logbook hierarchy: +
+
+
+
+ one would use following statements: +
+[global] Group Linux PCs = Red Hat, Debian, Mandrake Group Windows PCs = 98, ME, NT, XP, CE Group CE = 1.0, 2.0 -
-
-
- -Where the selected group or logbook becomes blue. The lower groups/logbooks change according -to the selected upper group. Please note that a logbook can be contained in more than one -group, but then it should not be the first logbook in those groups. The colors of the tabs -and the title bar can be specified in the CSS file.
- -
-
-Sometimes groups of logbooks should be completely separate. Imagine two groups of logbooks,
-one for the engineering department and one for the administration department. These groups
-should have different administrators, and the logbook tabs at the top of the screen should
-not show the logbooks from the other department. Prior to ELOG version 2.4.1, one had to
-run two elogd servers in parallel, listening under different ports. Since 2.4.1, one can achieve
-the same behaviour using Top groups. The configuration could look like this:
-
-
++ + The logbook tabs would then look like this: +
+
+
+ Where the selected group or logbook becomes blue. The lower + groups/logbooks change according to the selected upper group. Please note + that a logbook can be contained in more than one group, but then it + should not be the first logbook in those groups. The colors of the tabs + and the title bar can be specified in the CSS file. +
+
+ Sometimes groups of logbooks should be completely separate. Imagine two
+ groups of logbooks, one for the engineering department and one for the
+ administration department. These groups should have different
+ administrators, and the logbook tabs at the top of the screen should not
+ show the logbooks from the other department. Prior to ELOG version 2.4.1,
+ one had to run two elogd servers in parallel, listening under different
+ ports. Since 2.4.1, one can achieve the same behaviour using Top
+ groups. The configuration could look like this:
+
Group Linux PCs = Red Hat, Debian, Mandrake Group Windows PCs = 98, ME, NT, XP, CE Group CE = 1.0, 2.UL @@ -349,1057 +444,1194 @@ Admin user = stefan [global administration] Password file = admin.pwd Admin user = bill -
[global] section for each top level group of logbooks.
-The rule is that a configuration setting in an individual logbook section overrides a setting
-in the [global <top group>] setting, which by itsel overrides a setting
-in the [global] section. This way one can define settings for all top level
-groups (such as the SMTP host) in the [global] section, and define different
-password files and administrators in the individual top level group sections.
-http://your.host:8080/, this URL becomes
-invalid for top groups, to avoid the case that one group can "see" the logbooks of the other
-groups. Instead, one has to append the top group name to the URL, such as
-http://your.host:8080/engineering or
-http://your.host:8080/administration. If someone does not know the
-top group name, one cannot see the list of logbooks there, so the groups become completely
-independent of each other. If this feature is not wanted, it can be disabled by setting
-Show top groups = 1.- - -
-For each logbook, there is a section with the logbook name in square brackets, so that each
-logbook can have different options. If an option is not present in a logbook section, then the
-system tries to locate that option in the [global] section. Thus if the
-following options are placed in the [global] section, they are defaults for
-all logbooks. If they are present in the [global] and in the logbook
-section, the logbook option is used.
- -Here are the available options, by broad categories:
-
-
-
-
-
-
-
-
-
-
-
-
-
-<img border=0 src="elog.gif" alt="ELOG logo">
-
-This code can be replaced by
-
-
-
-
-
-
-
-
-
+ For each logbook, there is a section with the logbook name in square
+ brackets, so that each logbook can have different options. If an option
+ is not present in a logbook section, then the system tries to locate that
+ option in the
+ Here are the available options, by broad categories:
+
+ <img border=0 src="elog.gif" alt="ELOG logo">
+
+ This code can be replaced by
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Note that the presence of this option opens user access also to the find result or elog
-listing page, which usually contains some config command. So it is useful to combine
-the
-
-
-
-
+ Note that the presence of this option opens user access also to the
+ find result or elog listing page, which usually contains some config
+ command. So it is useful to combine the
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
Note that there can be a Data dir = <directory>
-
-This option is obsolete from version 2.2.5 on and should not be used. Use Subdir = ...
-instead.Subdir = <directory>
-
-Each logbook has a separate directory where the logbook entries are stored, which
-is controlled by this statement. If the directory does not exist, it is created
-autmatically by the elogd program. The subdirectory is relative
-to the logbook root directory specified with the Logbook dir = ...
-option. So if Logbook dir = /usr/local/elog/logbooks and
-Subdir = Demo then the logbook data is stored in
-/user/local/elog/logbooks/Demo. If the Logbook dir = ...
-option is not specified, then logbooks is used. If the subdirectory
-starts with a "/" ("\" under Windows), then it is used as an absolute path independent
-of the logbook dir. To see which directories are used, start elogd with the "-v" flag.
-Comment = <comment>
-
-The comment is displayed on the logbook selection list. The selection list is
-displayed if more than one logbook is defined on a host and no logbook is
-explicitly specified in the URL.
-Theme = <theme>
-
-A theme determines which layout and colors are used for a logbook, similar to
-skins in other programs. The theme option points to a subdirectory
-under the "themes" directory which resides in the resource directory.
-It contains all files for that theme. The format of these files is described under
-the Themes section.
-CSS = <filename>
-
-A given theme can contain several Cascading Style Sheets (CSS). This can be usefule
-if several logbooks use the same images and icons, but differnt colors. By default,
-the CSS default.css is used. This can be overwritten by this statement.
-Title image = <string>
-
-HTML code for the icon in the upper right corner. By default, following code
-is used:<string> to display a different
-icon file, or to display some text. The icon image has to be present in the theme directory,
-which is usually <elog root>/themes/default.
-Title image URL = <URL>
-
-The ELOG icon at the right upper corner usually points to the ELOG home page. This
-URL can be changed to point to a corporate page for example with this option. The
-icon can be changed by replacing the elog.gif icon in the
-theme directory. This option should only be used if the Title image
-option is not used.
-Time format = <string>
-
-This option determines how the date and time of a logbook entry is displayed. The format
-of the string is the same as the C function
-
-strftime, so a string of %A, %B %d, %Y, %H:%M yields in a display of
-Thursday, November 15, 2001, 12:35 for example.
-Date format = <string>
-
-This option determines how the date is displayed from attributes which are of type "date".
-The format of the string is the same as the C function
-
-strftime, so a string of %A, %B %d, %Y yields in a display of
-Thursday, November 15, 2001 for example.
-Welcome Page = <file>
-
-By default, the list with the last twenty entries of a logbook is displayed when the logbook is selected.
-This can be overridden with this option, which causes a HTML file to be shown
-instead of the message list. This file can contain further links for new logbook
-messages of for logbook queries. Here is a simple example of such a file:
-
+
+ [global] section for each
+ top level group of logbooks. The rule is that a configuration setting in an
+ individual logbook section overrides a setting in the [global
+ <top group>] setting, which by itsel overrides a setting
+ in the [global] section. This way one can define
+ settings for all top level groups (such as the SMTP host) in the
+ [global] section, and define different password files
+ and administrators in the individual top level group sections.
+
+ If top groups are used, the root of the elogd server is not accessible any
+ more. Presume that elogd is accessible normally under
+ http://your.host:8080/, this URL becomes invalid for
+ top groups, to avoid the case that one group can "see" the logbooks of the
+ other groups. Instead, one has to append the top group name to the URL,
+ such as http://your.host:8080/engineering or
+ http://your.host:8080/administration. If someone does
+ not know the top group name, one cannot see the list of logbooks there, so
+ the groups become completely independent of each other. If this feature is
+ not wanted, it can be disabled by setting Show top groups =
+ 1.
+
+ [global] section. Thus if the following
+ options are placed in the [global] section, they are
+ defaults for all logbooks. If they are present in the
+ [global] and in the logbook section, the logbook
+ option is used.
+
+
+
-
-Data dir = <directory>
+ This option is obsolete from version 2.2.5 on and should not be used.
+ Use Subdir = ... instead.
+ Subdir = <directory>
+ Each logbook has a separate directory where the logbook entries are
+ stored, which is controlled by this statement. If the directory does
+ not exist, it is created autmatically by the elogd
+ program. The subdirectory is relative to the logbook root directory
+ specified with the Logbook dir = ... option. So if
+ Logbook dir = /usr/local/elog/logbooks and
+ Subdir = Demo then the logbook data is stored in
+ /user/local/elog/logbooks/Demo. If the
+ Logbook dir = ... option is not specified, then
+ logbooks is used. If the subdirectory starts with a
+ "/" ("\" under Windows), then it is used as an absolute path
+ independent of the logbook dir. To see which directories are used,
+ start elogd with the "-v" flag.
+ Comment = <comment>
+ The comment is displayed on the logbook selection list. The selection
+ list is displayed if more than one logbook is defined on a host and no
+ logbook is explicitly specified in the URL.
+ Theme = <theme>
+ A theme determines which layout and colors are used for a logbook,
+ similar to skins in other programs. The theme option
+ points to a subdirectory under the "themes" directory which
+ resides in the resource directory. It contains all files for that
+ theme. The format of these files is described under the Themes
+ section.
+ CSS = <filename>
+ A given theme can contain several Cascading Style Sheets (CSS). This
+ can be usefule if several logbooks use the same images and icons, but
+ differnt colors. By default, the CSS default.css is used. This
+ can be overwritten by this statement.
+ Title image = <string>
+ HTML code for the icon in the upper right corner. By default, following
+ code is used:
+ <string> to
+ display a different icon file, or to display some text. The icon
+ image has to be present in the theme directory, which is usually
+ <elog root>/themes/default.
+ Title image URL = <URL>
+ The ELOG icon at the right upper corner usually points to the ELOG home
+ page. This URL can be changed to point to a corporate page for example
+ with this option. The icon can be changed by replacing the
+ elog.gif icon in the theme directory. This option
+ should only be used if the Title image option is
+ not used.
+ Time format = <string>
+ This option determines how the date and time of a logbook entry is
+ displayed. The format of the string is the same as the C function
+
+ strftime, so a string of %A, %B %d, %Y, %H:%M yields in a
+ display of Thursday, November 15, 2001, 12:35 for example.
+ Date format = <string>
+ This option determines how the date is displayed from attributes which
+ are of type "date". The format of the string is the same as the C
+ function
+ strftime, so a string of %A, %B %d, %Y yields in a display
+ of Thursday, November 15, 2001 for example.
+ Welcome Page = <file>
+ By default, the list with the last twenty entries of a logbook is
+ displayed when the logbook is selected. This can be overridden with
+ this option, which causes a HTML file to be shown instead of the
+ message list. This file can contain further links for new logbook
+ messages of for logbook queries. Here is a simple example of such a
+ file:
+
<h1>Welcome to the test logbook</h1>
<ul>
<li><a href="?cmd=new">Enter</a> a new message
<li><a href="?cmd=find">Search</a> the logbook
</ul>
-
-
-The file must be present in the resource directory.
-Alternatively, an absolute path can be used if the file name starts with a
-"/" (Unix) or "\" or "x:"
-(Windows).
-Start page = <command>
-
-This option can be used to display a different start page. command
-can be either 0?cmd=Last to display the last message, or any other ELog menu command in the
-form ?cmd=xxx. To start with the search page, one uses
+
The file must be present in the resource directory. Alternatively, an
+absolute path can be used if the file name starts with a
+"/" (Unix) or "\" or
+"x:" (Windows).
+ Start page = <command>
+ This option can be used to display a different start page.
+ command can be either 0?cmd=Last to display
+ the last message, or any other ELog menu command in the form
+ ?cmd=xxx. To start with the search page, one uses
+
Start page = ?cmd=Find
-
-
-Please note that if another language than English is selected via the Language = xxx option,
-the commands have to be in that language as well (like "Start page = 0?cmd=Letzter" for
-German).Submit Page = <file>
-
-This optional page can be displayed when a new message was submitted in a logbook.
-Here is an example:
-
+
Please note that if another language than English is selected via the
+ Language = xxx option, the commands have to be in that language as
+ well (like "Start page = 0?cmd=Letzter" for German).
+ Submit Page = <file>
+ This optional page can be displayed when a new message was submitted in
+ a logbook. Here is an example:
+
<h1>You successfully submitted a message</h1>
<a href="?cmd=Back">Back</a> to the logbook<p>
<a href="?cmd=New">Enter</a> another message
-
-
-The file must be present in the resource directory.
-Alternatively, an absolute path can be used if the file name starts with a
-"/" (Unix) or "\" or "x:"
-(Windows).
-Message comment = <comment>
-
-This optional comment is displayed on top of the text entry field when submitting
-a new message. It can contain a sentence like "Please enter your message here:".
-Reply comment = <comment>
-
-This optional comment is displayed on top of the text entry field when replying to an
-exiting entry. It can contain a sentence like "Please enter your reply here:".
-Attachment comment = <comment>
-
-This optional comment is displayed on top of the attachment sumbission section when entering
-a new message. It can contain a sentence like "Please upload your attachments here:".
-Menu commands = <list>
-
-This option specifies the menu commands displayed on top of a single logbook page. For
-certain installations, it can be useful to disable some commands. Following
-commands are possible:
-
-
-
-The commands are always in English, independent of the language = ...
-setting, and are automatically translated into the specified language.
-
-If this option is not present, following default is used:
-
-Menu commands = List, New, Edit, Delete, Reply, Duplicate, Find, Config, Help
-
-
-Copy to = <logbook list>
-Move to = <logbook list>
-
-The commands Copy to and Move to make it possible
-to copy or move a logbook entry from one logbook to another. By default, all logbooks except
-the current logbook are shown as a possible destination. With the configurations options
-Copy to = <logbook list> and Move to = <logbook list>
-it is possible to specify a list of destination logbooks, separated by commata. This can
-make sense if only certain logbooks make sense as destinations.List Menu commands = <list>
-
-This option specifies the menu commands displayed on top of the listing page.
-Although all commands from a above are possible,
-only the commands New, Find, Select, CSV Import, Config, Admin, Change
-password, Logout and Help make sense. The command
-Select can be used to select multiple messages for deletion or for moving to other
-logbooks. Once the Select command is clicked, check boxes appear in front
-of all entries which let the user select one or more entries. A new menu bar shows up with
-a Delete and optionally a Coyp to ... and
-Move to ... button, if these commands are present in the
-Menu commands list. Pressing one of these buttons deletes, copies or moves
-all selected logbook entries.Guest Menu commands = <list>
-
-This option specifies the menu commands for guest logins. A guest login happens if a
-password file is used, but someone accesses the logbook for the first time, which means
-that no username/password is given. In that case the commands from the guest menu
-are displayed, which usually contain a subset of the normal commands. A typical scenario
-is a logbook which only has commands to read the logbook on the guest menu, but no
-commands to write/edit entries. Instead, the login command is given in the guest
-menu, with which one can login as a real user (username and password have to match those
-from the password file), which then allowes full access via the "Menu commands" list.
-A typical example for the menu settings for this scenario are:
+
The file must be present in the resource directory. Alternatively, an
+absolute path can be used if the file name starts with a
+"/" (Unix) or "\" or
+"x:" (Windows).
+ Message comment = <comment>
+ This optional comment is displayed on top of the text entry field when
+ submitting a new message. It can contain a sentence like "Please
+ enter your message here:".
+ Reply comment = <comment>
+ This optional comment is displayed on top of the text entry field when
+ replying to an exiting entry. It can contain a sentence like "Please
+ enter your reply here:".
+ Attachment comment = <comment>
+ This optional comment is displayed on top of the attachment sumbission
+ section when entering a new message. It can contain a sentence like
+ "Please upload your attachments here:".
+ Menu commands = <list>
+ This option specifies the menu commands displayed on top of a single
+ logbook page. For certain installations, it can be useful to disable
+ some commands. Following commands are possible:
+
+
+
+ The commands are always in English, independent of the
+ language = ... setting, and are automatically
+ translated into the specified language.
+
+ If this option is not present, following default is used:
+
+Menu commands = List, New, Edit, Delete, Reply, Duplicate, Find, Config, Help
+
+ Copy to = <logbook list>
+ Move to = <logbook list>
+ The commands Copy to and Move
+ to make it possible to copy or move a logbook entry from one
+ logbook to another. By default, all logbooks except the current logbook
+ are shown as a possible destination. With the configurations options
+ Copy to = <logbook list> and Move to
+ = <logbook list> it is possible to specify a list of
+ destination logbooks, separated by commata. This can make sense if only
+ certain logbooks make sense as destinations.
+ List Menu commands = <list>
+ This option specifies the menu commands displayed on top of the listing
+ page. Although all commands from a above are possible, only the
+ commands New, Find, Select, CSV Import, Config, Admin, Change
+ password, Logout and Help make sense.
+ The command Select can be used to select multiple
+ messages for deletion or for moving to other logbooks. Once the
+ Select command is clicked, check boxes appear in
+ front of all entries which let the user select one or more entries. A
+ new menu bar shows up with a Delete and optionally
+ a Coyp to ... and Move to ...
+ button, if these commands are present in the Menu
+ commands list. Pressing one of these buttons deletes, copies
+ or moves all selected logbook entries.
+ Guest Menu commands = <list>
+ This option specifies the menu commands for guest logins. A guest login
+ happens if a password file is used, but someone accesses the logbook
+ for the first time, which means that no username/password is given. In
+ that case the commands from the guest menu are displayed, which usually
+ contain a subset of the normal commands. A typical scenario is a
+ logbook which only has commands to read the logbook on the guest menu,
+ but no commands to write/edit entries. Instead, the login
+ command is given in the guest menu, with which one can login as a real
+ user (username and password have to match those from the password
+ file), which then allowes full access via the "Menu commands"
+ list. A typical example for the menu settings for this scenario are:
+
Menu commands = List, New, Edit, Reply, Duplicate, Find, Config, Logout, Help
Guest menu commands = List, Find, Login, Help
-Guest menu commands option with the following
-Guest List Menu commands option to restrict the access to the
-find result page as well.
-Guest List Menu commands = <list>
-
-Same as Guest Menu commands but for the find result page.Menu text = <file>
-
-If this option is present, and additional menu row above the message gets displayed with
-the contents of <file>. This file can contain arbitrary text, images or links.
-One example would be following text to go back to the listing page and display the
-next Routine entry and all Routine entries:
-
-
+
Guest menu
+ commands option with the following Guest List
+ Menu commands option to restrict the access to the find
+ result page as well.
+ Guest List Menu commands = <list>
+ Same as Guest Menu commands but for the find result page.
+ Menu text = <file>
+ If this option is present, and additional menu row above the message
+ gets displayed with the contents of <file>. This file can contain
+ arbitrary text, images or links. One example would be following text to
+ go back to the listing page and display the next Routine entry
+ and all Routine entries:
+
<small>
- <a href="?cmd=next&type=Routine">Next Routine entry</a> |
+ <a href="?cmd=next&type=Routine">Next Routine entry</a> |
<a href="../?Type=Routine">All Routine entries</a>
</small>
-
-List Menu text = <file>
-
-The same for the list page. One example would be following text to
-switch between the different display modi:
-
-Filter Menu text = <file>
-
-The same for the filter line in the list page.
-
-Guest Display = <list>
-
-This option specifies which attributes are displayed on guest access. It is possible
-to display only a subset of all attributes for guest access, but the full list
-if someone is logged in (using the option "Password file"). The list
-consists of comma separated attributes, including the word text, if one
-wants to display the entry body text for guests.
+
List Menu text = <file>
+ The same for the list page. One example would be following text to
+ switch between the different display modi:
+ Filter Menu text = <file>
+ The same for the filter line in the list page.
+ Guest Display = <list>
+ This option specifies which attributes are displayed on guest access.
+ It is possible to display only a subset of all attributes for guest
+ access, but the full list if someone is logged in (using the option
+ "Password file"). The list consists of comma
+ separated attributes, including the word text, if one wants to
+ display the entry body text for guests.
+
<small>
<a href="?mode=summary">Summary</a> |
<a href="?mode=full">Full</a> |
<a href="?mode=threaded">Threaded</a> |
</small>
-
-Top text = <file> | <string>
-
-The text of this option gets displayed at the top of every Elog page.
-It can be a string or a filename which gets displayed. Might be useful
-to display company logos etc.
-
-
-If a file is specified, it must be present in the resource directory.
-Alternatively, an absolute path can be used if the file
-name starts with a "/" (Unix) or "\" or
-"x:" (Windows).
-Bottom text = <file> | <string>
-
-The text of this option gets displayed at the bottom of every Elog page
-instead of the little Elog home page link. It can be a string or a file.
-It can contain for example a link back to the main logbook selection page like:
-
-
+
Top text = <file> | <string>
+ The text of this option gets displayed at the top of every Elog page.
+ It can be a string or a filename which gets displayed. Might be useful
+ to display company logos etc.
+
+ If a file is specified, it must be present in the resource directory.
+ Alternatively, an absolute path can be used if the file name starts
+ with a "/" (Unix) or "\" or
+ "x:" (Windows).
+ Bottom text = <file> | <string>
+ The text of this option gets displayed at the bottom of every Elog page
+ instead of the little Elog home page link. It can be a string or a
+ file. It can contain for example a link back to the main logbook
+ selection page like:
+
<center><a href="/">Main page</a></center>
-
-
-Or it can contain other useful links. If a file is specified, it must
-be present in the resource directory.
-Alternatively, an absolute path can be used if the file
-name starts with a "/" (Unix) or "\" or
-"x:" (Windows).
-Help URL = <URL>
-
-
-This URL is used for the Help button. By default, the file eloghelp_xx.html is returned with
-the contents of the help page. Edit this file directly to add site-specific help for all logbooks.
-Alternatively, use the Help URL option to specify different help pages for different
-logbooks. It can point to a site-specific help page via http://... or to a local
-file like file://c:/tmp/config.html, or to the name of an HTML file which must be
-present in the resource directory. Message Width = <number>
-
-This value sets the number of characters per line of the main message entry field.
-The default value is 76 (78 for replies), and can be increased for installations
-which need a larger window size (like pasting log files etc.).
-Message Height = <number>
-
-This value sets the number of lines of the main message entry field.
-The default value is 20, and can be changed for installations
-which need a different window size.
-Admin textarea = <cols>,<rows>
-
-This defines the textarea size for the admin page. Default is 80,40.
-Display mode = [full|summary|threaded]
-
-Default mode for search display. On the find entry form, the checkboxes
-are set accordingly. The "Last xxx" page uses this setting directly.
-Entries per page = <number>
-
-Number of logbook entries displayed per page in a search result. The default is 20.
-Restrict edit time = <hours>
-
-If this option is set, a new message can only be edited a certain number of hours
-after its creation. This can be useful if one wants to ensure that old entries
-cannot be modified. Hours can also be fractional, like 0.5 for 30 min.
-Max content length = <bytes>
-
-This option restricts the size of attachments. When very large (>100MB) attachments
-are uploaded, the elogd server can be busy with this upload for a longer time and
-not respond to other requests during that time. To avoid this, the maximum size
-of attachments can be restricted. The server will then refuse to accept larger
-attachments. The default is 10485760 (= 10 MB). This option has to be placed
-into the [global] section and the elogd server has to be restarted after a change.Fonts = <list>
-
-List of fonts (comma separated) to be shown in the font drop-down box of the entry edit
-form. Default is
-Fonts = Arial, Comic Sans MS, Courier New, Tahoma, Times New Roman, Verdana
-
-On Unix systems some of these fonts might not be installed, in which case they can
-be replaced by others like Serif, Sans-serif, Helvetica.
-
-
-
+ Attributes = <list>
-
-Define a number of attributes for the logbook, separated by commata. A maximum of
-100 attributes can be defined. Typical values are "Author", "Subject"
-or "Type".
-Options <attribute> = <list>
-
-Usually, an text field is used for an attribute, where the user can fill in
-text of up to 100 characters. If instead a drop-down box with preset items is
-better for a given attribute, these items can be defined with this statement.
-Up to 100 items can be defined, separated by commas. To add an option including
-a comma, encose it in quotations marks like
+
Or it can contain other useful links. If a file is specified, it must be
+present in the resource directory. Alternatively, an absolute path can be used
+if the file name starts with a "/" (Unix) or
+ "\" or "x:" (Windows).
+ Help URL = <URL>
+ This URL is used for the Help button. By default, the file
+ eloghelp_xx.html is returned with the contents of the help page.
+ Edit this file directly to add site-specific help for all logbooks.
+ Alternatively, use the Help URL option to specify
+ different help pages for different logbooks. It can point to a
+ site-specific help page via http://... or to a
+ local file like file://c:/tmp/config.html, or to
+ the name of an HTML file which must be present in the resource
+ directory.
+ Message Width = <number>
+ This value sets the number of characters per line of the main message
+ entry field. The default value is 76 (78 for replies), and can be
+ increased for installations which need a larger window size (like
+ pasting log files etc.).
+ Message Height = <number>
+ This value sets the number of lines of the main message entry field.
+ The default value is 20, and can be changed for installations which
+ need a different window size.
+ Admin textarea = <cols>,<rows>
+ This defines the textarea size for the admin page. Default is
+ 80,40.
+ Display mode = [full|summary|threaded]
+ Default mode for search display. On the find entry form, the checkboxes
+ are set accordingly. The "Last xxx" page uses this setting directly.
+ Entries per page = <number>
+ Number of logbook entries displayed per page in a search result. The
+ default is 20.
+ Restrict edit time = <hours>
+ If this option is set, a new message can only be edited a certain
+ number of hours after its creation. This can be useful if one wants to
+ ensure that old entries cannot be modified. Hours can also be
+ fractional, like 0.5 for 30 min.
+ Max content length = <bytes>
+ This option restricts the size of attachments. When very large
+ (>100MB) attachments are uploaded, the elogd server can be busy with
+ this upload for a longer time and not respond to other requests during
+ that time. To avoid this, the maximum size of attachments can be
+ restricted. The server will then refuse to accept larger attachments.
+ The default is 10485760 (= 10 MB). This option has to be placed into
+ the [global] section and the elogd server has to be restarted after a
+ change.
+ Fonts = <list>
+ List of fonts (comma separated) to be shown in the font drop-down box
+ of the entry edit form. Default is
+
+ Fonts = Arial, Comic Sans MS, Courier New, Tahoma, Times New
+ Roman, Verdana
+
+ On Unix systems some of these fonts might not be installed, in which
+ case they can be replaced by others like Serif,
+ Sans-serif, Helvetica.
+
Attributes = <list>Options <attribute> = <list>Options town = San Francisco, "Paris, Texas", "Paris, France"-
- -
Extendable options = <list>
-Options <attribute> to specify a list
-of possible options, this list is fixed. Sometimes it is desirable to extend
-the list when a new entry in a logbook is made and a certain option is missing
-on the list. By adding the attribute name to the Extandable options
-list, a button appears next to the attribute in the message entry form which
-lets you add new options to the list. The elogd.cfg configuration file is
-then automatically updated. When a new logbook entry gets made, the new option
-automatically appears in the drop-down box for that attribute.
-- -
ROptions <attribute> = <list>
-Options above, but using radio buttons instead
-of a drop-down box.
-- -
MOptions <attribute> = <list>
--
+
Extendable options = <list>Options <attribute> to specify
+ a list of possible options, this list is fixed. Sometimes it is
+ desirable to extend the list when a new entry in a logbook is made and
+ a certain option is missing on the list. By adding the attribute name
+ to the Extandable options list, a button appears
+ next to the attribute in the message entry form which lets you add new
+ options to the list. The elogd.cfg configuration file is then
+ automatically updated. When a new logbook entry gets made, the new
+ option automatically appears in the drop-down box for that attribute.
+ ROptions <attribute> = <list>Options above, but using radio buttons
+ instead of a drop-down box.
+ MOptions <attribute> = <list><value1> | <value2> | ... --In the "find" page only one of these values can be specified, which is then -treated as a substring in the search filter. -
- -
IOptions <attribute> = <list>
--
+In the "find" page only one of these values can be specified, +which is then treated as a substring in the search filter. +
IOptions <attribute> = <list>Attributes = Author, Icon, Subject... IOptions Icon = icon1.gif, icon2.gif, icon3.gif, ... --New icons are welcome and should be sent back to the author to be incorporated -in the next version. -
- -
Comment <attribute> = <comment>
-- -
Tooltip <attribute> = <comment>
-Comment <attribute>, except that the comment
-gets displayed as a tooltip (tiny pup-up window) when the user moves the mouse
-cursor over the attribute name in the entry form.
-- -
Icon comment <icon> = <comment>
-- -
Options <attribute> = boolean
-- -
Preset <attribute> = <string>
--
+New icons are welcome and should be sent back to the author to be +incorporated in the next version. +
Comment <attribute> = <comment>Tooltip <attribute> = <comment>Comment <attribute>, except that the
+ comment gets displayed as a tooltip (tiny pup-up window) when the user
+ moves the mouse cursor over the attribute name in the entry form.
+ Icon comment <icon> = <comment>Options <attribute> = booleanPreset <attribute> = <string>Preset Author = $long_name --If the attribute should be locked at the Web submission, use the -"Locked Attributes = ..." option. If a preset value is given for an +If the attribute should be locked at the Web submission, use the +"Locked Attributes = ..." option. If a preset value is given for an attribute which has an options list, the preset value is selected in the drop -down box by default.
-
+down box by default.
+
+ A special option are automatically generated tags, which are + automatically incremented for each new message. This is achieved by + putting #'s into the preset string, which is used as a placeholder for + the incrementing index. Each "#" stands for one digit, thus the + statement +Preset Number = XYZ-##### --results in automatically created attributes "Number" of the form-
+results in automatically created attributes "Number" of the form +XYZ-00001 XYZ-00002 XYZ-00003 --and so on. In addition to the #'s one may specify format specifiers which are passed -to the -strftime function. This allows to create tags wich contain the current year, month -and so on. Once the date part of the attribute changes, the index restarts from one. -The statement --
+and so on. In addition to the #'s one may specify format specifiers which +are passed to the + strftime function. This allows to create tags wich contain the + current year, month and so on. Once the date part of the attribute + changes, the index restarts from one. The statement +Preset Number = XYZ-%Y-%b-### --results in automatically created attributes "Number" of the form-
+results in automatically created attributes "Number" of the form +XYZ-2005-Oct-001 XYZ-2005-Oct-002 XYZ-2005-Oct-003--and -
-
++ and +
+XYZ-2005-Nov-001 XYZ-2005-Nov-002--on the next month. -
- -
Preset text = <string> or <file>
-"/" (Unix) or "\" or "x:"
-(Windows).
-- -
Preset on reply <attribute> = <string>
-Preset <attribute>, but evaluated for
-replies.
-- -
Locked Attributes = <list>
-- -
Fixed Attributes Edit = <list>
-Edit button. This feature can be
-useful to preserve the original author of the message, when using the
-Preset Author = $long_name option as described above.
-- -
Fixed Attributes Reply = <list>
-Reply button. This feature can be
-useful to preserve the original subject of a message for example.
-- -
Required Attributes = <list>
-- -
Page title = <string>
-- -
Edit Page title = <string>
-- -
List display = <list>
-ID for the entry ID
-Date for the entry date/time
-Edit to display a column with an edit icon to directly edit
-and entry
-Delete to display a column with a delete icon to directly delete
-and entry
-++ on the next month. +
+
Preset text = <string> or <file>"/" (Unix) or "\" or
+ "x:" (Windows).
+ Preset on reply <attribute> =
+ <string>Preset <attribute>, but evaluated for
+ replies.
+ Locked Attributes = <list>Fixed Attributes Edit = <list>Edit button. This feature can
+ be useful to preserve the original author of the message, when using
+ the Preset Author = $long_name option as described
+ above.
+ Fixed Attributes Reply = <list>Reply button. This feature
+ can be useful to preserve the original subject of a message for
+ example.
+ Required Attributes = <list>Hidden Attributes = <list>Change <attribute>
+ command.
+ Page title = <string>Edit Page title = <string>List display = <list>ID for the entry ID
+ Date for the entry date/time
+ Edit to display a column with an edit icon to
+ directly edit and entry
+ Delete to display a column with a delete icon
+ to directly delete and entry
+ List display = ID, Date, <all attributs> +Which displays the message number, date, and all attributes. The display +of the message body is controlled by the
Display mode and
+Summary lines options. If a search goes over "all
+logbooks", an additional colums with the logbook name of each entry is added in
+front.
+ Guest List display = <list>List display, but for guest access (user
+ level access with password, but not logged in). Please see also
+ Guest display. In addition to List
+ display, one can optionally specify Text
+ as an attribute here. Without that attribute, the summary text of the
+ entry body is not shown. This makes it possible to show the text for
+ registered users and hide it for guest access.
+ Link display = <list>Thread display = <string>+Thread display = $subject, posted by $author on $entry time-Which displays the message number, date, and all attributes. The display of the -message body is controlled by the
Display mode and
-Summary lines options. If a search goes over "all logbooks",
-an additional colums with the logbook name of each entry is added in front.
-- -
Guest List display = <list>
-List display, but for guest access (user level
-access with password, but not logged in). Please see also Guest
-display. In addition to List display, one can
-optionally specify Text as an attribute here. Without that
-attribute, the summary text of the entry body is not shown. This makes it possible
-to show the text for registered users and hide it for guest access.
-- -
Link display = <list>
-- -
Thread display = <string>
--
Thread display = $subject, posted by $author on $entry time-
- -
Thread icon = <attribute>
-- -
RSS Title = <string>
--
RSS Title = $subject, posted by $author on $entry time-
- -
RSS Entries = <n>
-- -
Subst <attribute> = <string>
--
elogd is running
-Subst Author = $author from $remote_host-
+
Thread icon = <attribute>RSS Title = <string>+RSS Title = $subject, posted by $author on $entry time ++
RSS Entries = <n>Subst <attribute> = <string>elogd is
+ running
+ +Subst Author = $author from $remote_host +
Subst Info = $shell(cat /tmp/filename) (Unix) Subst Info = $shell(type c:\tmp\filename) (Windows)-
- -
Remove on reply = <list>
-- -
Quote on reply = 0 | 1
-- -
Reply string = <string>
-"> ". Can
-be empty string ("") if no message marking is desired.
-- -
Subst on reply <attribute > = <string>
-Subst on reply subject = Re: $subject-
- -
Subst on edit <attribute > = <string>
-Subst on edit author = $full_name-
- -
Quick filter = <list>
-Attributes = list, the attribute Date and the
-option Subtext can be listed here. Using the Date
-filter, the last day, week, month and so on can be displayed. The Subtext
-filter works on the entry body text.
-- -
Format <attribute> = <flags>,<css_class_name>,<css_class_value>,<width>,<size>
-- -Values used for single message display page: -
- -Values used for new message entry form: -
- -Default is "0, attribname, attribvalue, 80, 500". Trailing parameters can be ommitted, -so specifying for example only the flags is possible. -
- -
Type <attribute> = date | datetime | numeric | userlist
-date are treated as a date. Their format for
-display can be controlled by the Date format option.
-Upon entry, drop-down boxes are displayed which let the user select the day, month and
-year. Alternatively, a pop-up date picker using a calendar can be displayed if JavaScript
-is enabled. Date attributes are saved internally as seconds since 1.1.1970, and can therefore
-be sorted propoerly by clicking on the header of a logbook entry list. On the find page,
-dates can be searched for via a start and end date. If date attributes are used in a quick filter
-(see above), a drop-down quick filter box is displayed which lets the user select "last day",
-"last week", "next week", and so on. The datetime type combines
-a date and time in HH:MM. The output of this combination is controlled by the
-Time format option.userlist, a drop-down box is displayed which contains
-all user names from the current password file. This can be useful for example in a bug
-tracking system, where a new entry gets assigned to an individual.- -
Change <attribute> = <string>
--http://any.company.com/telbook.cgi?search=<name> +
Remove on reply = <list>Quote on reply = 0 | 1Reply string = <string>">
+ ". Can be empty string ("") if no message marking is
+ desired.
+ Subst on reply <attribute > =
+ <string>+Subst on reply subject = Re: $subject+
Subst on edit <attribute > =
+ <string>+Subst on edit author = $full_name ++
Quick filter = <list>Attributes
+ = list, the attribute Date and the
+ option Subtext can be listed here. Using the
+ Date filter, the last day, week, month and so on
+ can be displayed. The Subtext filter works on the
+ entry body text.
+ Format <attribute> =
+ <flags>,<css_class_name>,<css_class_value>,<width>,<size>+ Optional formatting parameters for attributes. Following items can be + defined in the comma-separated list: ++ Values used for single message display page: +
+
+ Values used for new message entry form: +
++ Default is "0, attribname, attribvalue, 80, 500". Trailing + parameters can be ommitted, so specifying for example only the flags + is possible. +
+Type <attribute> = date | datetime | numeric |
+ userlistdate are treated as a date.
+ Their format for display can be controlled by the Date
+ format option. Upon entry, drop-down boxes are displayed
+ which let the user select the day, month and year. Alternatively, a
+ pop-up date picker using a calendar can be displayed if JavaScript is
+ enabled. Date attributes are saved internally as seconds since
+ 1.1.1970, and can therefore be sorted propoerly by clicking on the
+ header of a logbook entry list. On the find page, dates can be searched
+ for via a start and end date. If date attributes are used in a quick
+ filter (see above), a drop-down quick filter box is displayed which
+ lets the user select "last day", "last week", "next week", and so on.
+ The datetime type combines a date and time in
+ HH:MM. The output of this combination is controlled by the
+ Time format option.userlist, a drop-down box
+ is displayed which contains all user names from the current password
+ file. This can be useful for example in a bug tracking system, where a
+ new entry gets assigned to an individual.
+ Change <attribute> = <string>+http://any.company.com/telbook.cgi?search=<name> +where <name> has to be replaced by a search string. Now one can +construct an automatic telephonebook lookup with following options:
Attributes = Name, Telephone, ... Display Telephone = <a href="http://any.company.com/telbook.cgi?search=$Name">$Name's telephone number</a> -- -The attribute
Telephone is now automatically constructed from
-the attribute Name and consists of a link to the company's
-telephonebook. The advantage of this system is if the URL of the telephonebook
-changes one day, only one statement in the config file has to be changed, while
-otherways (like with the Subst Telephone = ... option) all
-entries would have to be changed manually.- -
List Change <attribute> = <string>
-- -
Execute new | edit | delete = <command>
-<command> can
-contain substitutions similar to the Subst command. In addition
-the list of all attachments can be referred to via <$attachemnts>
-Following (Unix) command writes a notification into some file:- -
-Execute new = echo "New message of type $type from $long_name on $remote_host" >> /tmp/elog.log -- -
Config command of elogd, that person
-can put malicious code into elogd.cfg and execute it. This is even more severe if elogd
-runs with root privileges. To avoid such problems, the execute facility is disabled
-in elogd by default and has to be enabled explicitly with the "-x" command line flag.
-The administrator has to ensure then of course that only trusted people can edit elogd.cfg.
-- -
Last submission = <string>
-$entry time by $author. If
-a logbook does not contain an author attribute, another string can
-be chosen.
-- -
ID display = <string>
-- -
+The attribute
Telephone is now automatically
+constructed from the attribute Name and consists of a link
+to the company's telephonebook. The advantage of this system is if the URL of
+the telephonebook changes one day, only one statement in the config file has to
+be changed, while otherways (like with the Subst Telephone =
+... option) all entries would have to be changed manually.
+ List Change <attribute> = <string>Execute new | edit | delete = <command><command> can contain
+ substitutions similar to the Subst command. In
+ addition the list of all attachments can be referred to via
+ <$attachemnts> Following (Unix) command
+ writes a notification into some file:
+ +Execute new = echo "New message of type $type from $long_name on $remote_host" >> /tmp/elog.log +
Config
+ command of elogd, that person can put malicious code into elogd.cfg and
+ execute it. This is even more severe if elogd runs with root
+ privileges. To avoid such problems, the execute facility is disabled in
+ elogd by default and has to be enabled explicitly with the "-x" command
+ line flag. The administrator has to ensure then of course that only
+ trusted people can edit elogd.cfg.
+ Last submission = <string>$entry time by $author. If a logbook does not
+ contain an author attribute, another string can be
+ chosen.
+ ID display = <string>ID display = TAG-$message id -
- -
Prepend on reply = <string>
-Prepend on reply = Added $date by $long_name\n\n- -
Append on reply = <string>
-- -
Prepend on edit = <string>
-Append on edit = <string>
-
-Same as before, but for editing entries.
-- -
Sort Attributes = <list>
-- -
- -When entering data into a elog form, it might be helpful to change the options of the attributes -depending on the value of other attributes. Let's assume you have a logbook containing entries -for different computers with different operating systems. Your elogd.cfg file starts like that: -
- -
++ + would display the entry ID as "TAG-1","TAG-2", ... and so on. + +
Prepend on reply = <string>Prepend on reply = Added $date by
+ $long_name\n\nAppend on reply = <string>Prepend on edit = <string>
+ Append on edit = <string>Sort Attributes = <list>+ When entering data into a elog form, it might be helpful to change the + options of the attributes depending on the value of other attributes. + Let's assume you have a logbook containing entries for different + computers with different operating systems. Your elogd.cfg file starts + like that: +
+Attributes = PC Name, Operating System, Version Options Operating System = Linux, Windows -
- -For the operating system version, you would like a list, but this list has to be different -for Linux and Windows. This can be achieved with conditional attributes. Simply write -following configuration: -
- -
++ + +
+ For the operating system version, you would like a list, but this list + has to be different for Linux and Windows. This can be achieved with + conditional attributes. Simply write following configuration: +
+
Attributes = PC Name, Operating System, Version
Options Operating System = Linux{1}, Windows{2}
{1} Options Version = 2.2, 2.4, 2.6
{2} Options Version = ME, 2k, NT, XP
-
-
-If you enter a new entry into that logbook, the drop-down list for Version
-changes automatically depending on the Operating System. Note that you
-have to enable Java Script for this to work. Without Java Script, a separate button appears
-in the line of the Operating System which has to be pressed to make the Version list change.
-
- -The number {1} and {2} in the configuration file are called conditions. Depending -on these conditions, certain other lines can be activated. So if the Operating System -Linux is selected, condition {1} is true, which selects the line starting -with {1} to select the options 2.2, 2.4, 2.6. -
-
-This technique offers various other possibilities, since any configuration option can
-be made conditional by adding a {<n>} in front of that line
-where <n> is an arbitrary number. One often used possibility is the definition
-of forms. Depending on an attribute, the configuration option
-Preset text = ... can be used to copy some pre-defined forms into
-the message body, which can then be filled out. Consider following example:
-
- -
++ + +
+ If you enter a new entry into that logbook, the drop-down list for
+ Version changes automatically depending on the
+ Operating System. Note that you have to enable Java
+ Script for this to work. Without Java Script, a separate button appears
+ in the line of the Operating System which has to be pressed to make the
+ Version list change.
+
+ The number {1} and {2} in the configuration file are called + conditions. Depending on these conditions, certain other lines can + be activated. So if the Operating System Linux is selected, + condition {1} is true, which selects the line starting with {1} to select + the options 2.2, 2.4, 2.6. +
+
+ This technique offers various other possibilities, since any
+ configuration option can be made conditional by adding a
+ {<n>} in front of that line where <n> is
+ an arbitrary number. One often used possibility is the definition of
+ forms. Depending on an attribute, the configuration option
+ Preset text = ... can be used to copy some
+ pre-defined forms into the message body, which can then be filled out.
+ Consider following example:
+
Attributes = Author, Type
Options Type = Network check{1}, System check{2}
{1} Preset text = network.txt
{2} Preset text = system.txt
--This causes two text files network.txt and system.txt to be copied -into the message body when a new entry is made. The file network.txt could -look like: -
- -
++ + +
+ This causes two text files network.txt and system.txt to be + copied into the message body when a new entry is made. The file + network.txt could look like: +
+Routers checked: [ ] DHCP checked: [ ] Comment: ... -
- -This works like a pre-defined form, the user puts X's between the "[ ]" when that -item has been checked. Other possibilities are pre-defined shift sheets in environments -where elog is uses as a shift logbook. The shift sheet could contain the names -of the shift crew, some check-list for standard tasks etc. -
-
-Another use of conditional attributes is in conjunction with the option
-Message comment. Depending on some attribute values, different
-message comment can be displayed to tell the user what to enter exactly in the
-message body for that attribute value.
-
- -
Show Attributes = <list>
-- -
++
+ This works like a pre-defined form, the user puts X's between the "[ ]" + when that item has been checked. Other possibilities are pre-defined + shift sheets in environments where elog is uses as a shift logbook. The + shift sheet could contain the names of the shift crew, some check-list + for standard tasks etc. +
+
+ Another use of conditional attributes is in conjunction with the option
+ Message comment. Depending on some attribute values,
+ different message comment can be displayed to tell the user what to enter
+ exactly in the message body for that attribute value.
+
+ Show Attributes = <list>
+ When using conditional attributes, it might be necessary to omit certain
+ attributes under certain conditions, to make the input mask shorter and
+ maybe change the order of the attributes. With this option, a subset of
+ all attributes can be specified which get displayed on the new entry
+ input page in the same order as they are specified here. This option only
+ makes sense when used with conditions, such as:
+
Attributes = PC Name, Operating System, Version, Distribution
Options Operating System = Linux{1}, Windows{2}
{1} Show Attributes = Operating System, Distribution, PC Name
{2} Show Attributes = Operating System, PC Name, Version
-
-
-The above statements caus the atrribute Version to be only
-visible when "Windows" is selected, and Distribution to be only
-visible when "Linux" is selected. If "Windows" is selected, the PC name is shown
-before the version.
- -
- -
++ + +
+ The above statements caus the atrribute Version to be
+ only visible when "Windows" is selected, and
+ Distribution to be only visible when "Linux" is
+ selected. If "Windows" is selected, the PC name is shown before the
+ version.
+
Attributes = PC Name, Operating System, Version, Location, Floor
Options Operating System = Linux{1}, Windows{2}
Options Location = Main Building{a}, New Building{b}, Old Building{c}
@@ -1407,751 +1639,1015 @@ Options Location = Main Building{a}, New Building{b}, Old Building{c}
{2} Options Version = ME, 2k, NT, XP
{a} Options Floor = Ground, First, Second
{b,c} Options Floor = Ground, First
-- -It is possible to specify an OR of several conditions like in the case {b,c}. This is -also possible over several conditions, like {1,a} would mean -"The PC has Linux or is in the Main Building". To specify a AND between -conditions, a "&" is used. The condition -
-
-{1&a} ...
-
-
-specifies for example the condition "Linux AND Main Building".
-
-
-Reading and writing into logbooks can be constrained using two different access methods,
-either with global passwords for read, write and admin (config, delete), or with user-
-level passwords. Both methods can be combined on the same server using different logbooks.
-For these two schemes to work properly, cookies have to be turned
-on in your browser. Please consult your browser documentation about how to do that.
-
-
-
-These optional password statements define passwords for reading and writing to the
-logbook, to delete entries in the logbook and to configure a logbook via the Config menu. The passwords are stored in an encoded form. To change them, use
-
-
-The read password is queried by the browser with a pop-up window and usually stays
-active for the entire browser session. The write and admin passwords are stored in
-cookies on the browser side and expire after the browser session. This time can be
-changed with the statement
-
-
-An alternative to the read/write/admin passwords is the user level access with a
-password file. This file contains user names and passwords in following format:
-
-
+ It is possible to specify an OR of several conditions like in the case
+ {b,c}. This is also possible over several conditions, like {1,a} would
+ mean "The PC has Linux or is in the Main Building". To specify a
+ AND between conditions, a "&" is used. The condition
+
+ Reading and writing into logbooks can be constrained using two different
+ access methods, either with global passwords for read, write and admin
+ (config, delete), or with user- level passwords. Both methods can be
+ combined on the same server using different logbooks. For these two
+ schemes to work properly, cookies have to be turned on in your
+ browser. Please consult your browser documentation about how to do
+ that.
+
+ These optional password statements define passwords for reading and
+ writing to the logbook, to delete entries in the logbook and to configure
+ a logbook via the Config menu. The passwords are stored in an
+ encoded form. To change them, use
+ The read password is queried by the browser with a pop-up window and
+ usually stays active for the entire browser session. The write and admin
+ passwords are stored in cookies on the browser side and expire after the
+ browser session. This time can be changed with the statement
+
+ An alternative to the read/write/admin passwords is the user level access
+ with a password file. This file contains user names and passwords in
+ following format:
+
-
-The passwords are encoded. New users can either be created by hitting Register as new user
-on the login page if
-
-To start a new password file, follow these steps:
-
-
-
-The presence of a password file requires all users to "log in" using their name and
-password, except when a guest login is allowed via the "Guest menu commands" option.
-An additional advantage of this method is that the user name can be used as
-an attribute value for creating logbook entries. For example, the following line could be
-added to the configuration file to fill in the Author and the Email attributes
-with the current user name and email:
-
-
-Thus the author name is not user-input anymore, ensuring the entry always contains the
-actual user name. For a full listing of substitutions, see the "Subst <attrib>" option.
-
-The user name and password are stored as cookies on the user side. The expiration is
-controlled by the
-
-The
-
-The
-
-
-
-With this option it is possible for new users to self-register an user account. At the
-login page, a link is displayed "Register as a new user" which leads the user to
-a configuration page where one can enter the account name, full name and email address.
-A flag allows for automatic email notification on new entries on the logbook. These
-settings can later be changed with the Config menu command.
-
-Setting this option to 0 disables self registration. With option 1, users
-can silently register, while setting it to 2 causes elogd to send an email
-notification to the admin user(s). The option 3 is used to only send an
-email notification to tha admin users(s), which then can validate the account and commit
-it by hitting the URL given in the email notification.
-
-
-
-Enables or disabled the ability for users to change their password. If disabled,
-the "Forgot password? link in the login page is ommitted as well.
-The admin user(s) can always change passwords.
-
-
-
-Commands can be restricted to certain login names (separated by commas). For
-each command in the list defined with the "Menu commands" option, a list of
-user names can be specified, which are allowed to execute that command. If the
-allow option is not present, all users may execute that command by default.
-
-
-
-Used to deny a certain command to a list of users. This can be used to deny
-a guest user to enter new messages or modify a message.
-
-
-
-These two settings can be used to restrict the access to the logbook to certain
-computers. It is similar to the UNIX hosts.allow and hosts.deny files.
-The list can consist of individual host names or IP numbers, subnet masks like
-
-These rules are applied before any password is checked. To debug problems,
-start
-
-The global option
-
-If any of the password statements are in the
-
-
-To send email automatically when new entries are created in a logbook, a
-
-Multiple The statement
-
-The option
-
-If the flag The flag
-
-If one wants to send only some attributes but not all in an email notification,
-one can use the option
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Themes are layout and color schemes which determine the look and feel of a logbook
-(sometimes called "skins"). A theme
-consists of a set of images, which are used for the title banner and browse buttons, and
-a Cascading Style Scheet (CSS), which defines the colors, fonts and spacing of the ELOG pages.
-
-
-Each theme resides in a separate subdirectory and is specified with the
-
-
-A default theme is contained in the distribution. If new themes are developed by users,
-they can be sent back to the author, to be included in future releases.
-
-
-To change colors and fonts, the source of a ELOG page can be examined. All elements use
-CSS classes which are specified in the
-
-If the CSS file is edited, most browsers require a "reload" to refresh the modified file.
-The elogd daemon does not have to be restarted after a change in the CSS file.
-
-These two images display the same logbook entry using different themes:
-
-
-
-
-Sometimes it can be useful to have the same ELOG logbook on two different computers. This
-might be the case if you travel with your laptop, but want to keep the logbooks from your
-desktop computer on the laptop. The problem is that if you add an entry on your laptop,
-the logbooks on the laptop and the desktop get out of sync. Merging only the ELOG database
-files does not help, since two entries could be made at the same day on the laptop and
-the desktop, which would lead to a conflict in that day's database file.
-
-
-To solve this problem, mirroring was introduced from Version 2.5.0 on. This technology
-allows to synchronize one ELOG server with a number of other servers on a per-entry basis. No
-additional software is needed, only two elogd daemons talking to each other. The synchronization
-can be executed manually or periodically. If entries are changed/added/deleted on both sides,
-they get merged properly during synchronization. In order to minimize network traffic, each
-ELOG server calculates a MD5 checksum for each message, which gets exchanged during synchronization.
-Only when the MD5 checksum differs, entries are transferred.
-
-
-To set-up mirroring, install two elogd servers on two machines (for testing purpose that also
-works on one machine with two elogd servers running on different ports). This can be done in
-two ways:
-
-
-
-A complete elog server can be transferred to a secondary server using the
-
-
-
-This command tells elogd to retrieve the configuration file, and optionally all logbook entries
-and password files from the master machine. Note that both servers must be version 2.5.4 or later.
-In case of trouble, you can turn on verbose messaging:
-
-
-
-which could give some hints. If a logbook on the master server uses restricted access, you have
-to specify the admin user name and password. After everything has been transferred, you can start
-elogd in the normal way.
-
-
-
-First, copy the elogd.cfg file from the master to the slave server. Make sure that
-the files are identical (except the port setting if you run two servers on the same
-machine). Then, add the following configuration options. They should be put
-into the [global] section of the cofiguration file:
-
-
-
-
-
-If the statement
-
-By starting the synchronization on one elogd server, this server becomes the client
-and the other one becomes the server. This means that the local server actively compares
-the local and the remote messages, and updates one or the other if necessary.
-The other (remote) server does not need to have any mirror option in its configuration
-file, since the local server simulates a web browser to send and retrieve messages to
-the remote server. It is however allowed that the remote server also contains some
-mirror settings in the configuration file, this way the synchronization can be
-started from both servers.
-
-
-
+ The passwords are encoded. New users can either be created by hitting
+ Register as new user on the login page if
+ To start a new password file, follow these steps:
+
+ The presence of a password file requires all users to "log in"
+ using their name and password, except when a guest login is allowed via
+ the "Guest menu commands" option. An additional advantage of this
+ method is that the user name can be used as an attribute value for
+ creating logbook entries. For example, the following line could be added
+ to the configuration file to fill in the Author and the
+ Email attributes with the current user name and email:
+
+ Thus the author name is not user-input anymore, ensuring the entry always
+ contains the actual user name. For a full listing of substitutions, see
+ the "Subst <attrib>" option.
+
+ The user name and password are stored as cookies on the user side. The
+ expiration is controlled by the
+ The
+ The
+ With this option it is possible for new users to self-register an user
+ account. At the login page, a link is displayed "Register as a new
+ user" which leads the user to a configuration page where one can
+ enter the account name, full name and email address. A flag allows for
+ automatic email notification on new entries on the logbook. These
+ settings can later be changed with the Config menu command.
+
+ Setting this option to 0 disables self registration. With option
+ 1, users can silently register, while setting it to 2
+ causes elogd to send an email notification to the admin user(s). The
+ option 3 is used to only send an email notification to tha
+ admin users(s), which then can validate the account and commit it by
+ hitting the URL given in the email notification.
+
+ Enables or disabled the ability for users to change their password. If
+ disabled, the "Forgot password? link in the login page is ommitted
+ as well. The admin user(s) can always change passwords.
+
+ Commands can be restricted to certain login names (separated by commas).
+ For each command in the list defined with the "Menu commands"
+ option, a list of user names can be specified, which are allowed to
+ execute that command. If the allow option is not present, all users may
+ execute that command by default.
+
+ Used to deny a certain command to a list of users. This can be used to
+ deny a guest user to enter new messages or modify a message.
+
+ These two settings can be used to restrict the access to the logbook to
+ certain computers. It is similar to the UNIX hosts.allow and
+ hosts.deny files. The list can consist of individual host names or
+ IP numbers, subnet masks like
+ These rules are applied before any password is checked. To debug
+ problems, start
+ The global option
+ If any of the password statements are in the
+ To send email automatically when new entries are created in a logbook, a
+
+ Multiple
+ The statement
+ The option
+ If the flag
+ The flag
+ If one wants to send only some attributes but not all in an email
+ notification, one can use the option
+ Themes are layout and color schemes which determine the look and feel of
+ a logbook (sometimes called "skins"). A theme consists of a set of
+ images, which are used for the title banner and browse buttons, and a
+ Cascading Style Scheet (CSS), which defines the colors, fonts and spacing
+ of the ELOG pages.
+
+ Each theme resides in a separate subdirectory and is specified with the
+
+ A default theme is contained in the distribution. If new themes are
+ developed by users, they can be sent back to the author, to be included
+ in future releases.
+
+ To change colors and fonts, the source of a ELOG page can be examined.
+ All elements use CSS classes which are specified in the
+
+ If the CSS file is edited, most browsers require a "reload" to refresh
+ the modified file. The elogd daemon does not have to be restarted
+ after a change in the CSS file.
+
+ These two images display the same logbook entry using different themes:
+
+
+ Sometimes it can be useful to have the same ELOG logbook on two different
+ computers. This might be the case if you travel with your laptop, but
+ want to keep the logbooks from your desktop computer on the laptop. The
+ problem is that if you add an entry on your laptop, the logbooks on the
+ laptop and the desktop get out of sync. Merging only the ELOG database
+ files does not help, since two entries could be made at the same day on
+ the laptop and the desktop, which would lead to a conflict in that day's
+ database file.
+
+ To solve this problem, mirroring was introduced from Version 2.5.0
+ on. This technology allows to synchronize one ELOG server with a number
+ of other servers on a per-entry basis. No additional software is needed,
+ only two elogd daemons talking to each other. The synchronization can be
+ executed manually or periodically. If entries are changed/added/deleted
+ on both sides, they get merged properly during synchronization. In order
+ to minimize network traffic, each ELOG server calculates a MD5 checksum
+ for each message, which gets exchanged during synchronization. Only when
+ the MD5 checksum differs, entries are transferred.
+
+ To set-up mirroring, install two elogd servers on two machines (for
+ testing purpose that also works on one machine with two elogd servers
+ running on different ports). This can be done in two ways:
+
+ A complete elog server can be transferred to a secondary server using
+ the
+ This command tells elogd to retrieve the configuration file, and
+ optionally all logbook entries and password files from the master
+ machine. Note that both servers must be version 2.5.4 or later. In
+ case of trouble, you can turn on verbose messaging:
+
+ which could give some hints. If a logbook on the master server uses
+ restricted access, you have to specify the admin user name and
+ password. After everything has been transferred, you can start elogd
+ in the normal way.
+
+ First, copy the elogd.cfg file from the master to the slave server.
+ Make sure that the files are identical (except the port setting if
+ you run two servers on the same machine). Then, add the following
+ configuration options. They should be put into the [global] section
+ of the cofiguration file:
+
+ If the statement
+ By starting the synchronization on one elogd server, this server becomes
+ the client and the other one becomes the server. This means that the
+ local server actively compares the local and the remote messages, and
+ updates one or the other if necessary. The other (remote) server does not
+ need to have any mirror option in its configuration file, since the local
+ server simulates a web browser to send and retrieve messages to the
+ remote server. It is however allowed that the remote server also contains
+ some mirror settings in the configuration file, this way the
+ synchronization can be started from both servers.
+
-
-
-Read password = <encoded password>
-Write password = <encoded password>
-Admin password = <encoded password>
-Write password expiration = <hours>
-Admin password expiration = <hours>
-elogd
- directly with the -r , -w and
--a flags. To set the write password of logbook "linux" to "
-test", enter: elogd -w test -l linuxWrite Password Expiration = x or
-Admin Password Expiration = x, where x is the expiration time in
-hours. It should be noted that on some systems the daylight savings time is calculated
-incorrectly, which can cause time offsets of one hour between a server PC and a client
-PC. In this case one hour must be added to the expiration time. If the expiration is set
-to "0", which is the default, the passwords are kept for the current browser session
-only. When the browser is restarted, the password must be re-entered.
-
-Password file = <file>
-Login expiration = <hours>
-Admin user = <user list>
-Login user = <user list>
-
+ <login name1>:<password1>:<full name1>:<email1>:<notify1>
+
+
+
+
specifies for example the condition "Linux AND Main Building".
+
+
+{1&a} ...
+
+
+
+
+ Read password = <encoded password>
+ Write password = <encoded password>
+ Admin password = <encoded password>
+ Write password expiration = <hours>
+ Admin password expiration = <hours>
+ elogd directly with
+ the -r , -w and
+ -a flags. To set the write password of logbook
+ "linux" to "test", enter:
+
+
+ elogd -w test -l linux
+ Write Password Expiration = x or Admin
+ Password Expiration = x, where x is the expiration time
+ in hours. It should be noted that on some systems the daylight savings
+ time is calculated incorrectly, which can cause time offsets of one hour
+ between a server PC and a client PC. In this case one hour must be added
+ to the expiration time. If the expiration is set to "0", which is the
+ default, the passwords are kept for the current browser session only.
+ When the browser is restarted, the password must be re-entered.
+
+
+ Password file = <file>
+ Login expiration = <hours>
+ Admin user = <user list>
+ Login user = <user list>
+
+
-
+<login name1>:<password1>:<full name1>:<email1>:<notify1>
<login name2>:<password2>:<full name2>:<email2>:<notify2>
<login name3>:<password3>:<full name3>:<email3>:<notify3>
-...
Self register = 1 in the configuration file, or
-by the admin user in the Config page by pressing New user. When a user is
-logged it, the entry for this user can be modified via the Config command.
-
Password file = <file> in the configuration file
-Self register = 1 in the configuration file
-
-Guest menu commands entry, you have to click on "Login" to get that screen.
-Admin user = <user> into the configuration file, using
-your login name from above
-
-Attributes = Author, Email, ...
-Subst Author = $long_name from $remote_host
-Subst Email = $user_emailRemember me checkbox during the login. If unchecked,
-the cookies expire after the
-current browser session. If checked, they expire after 31 days by default, which
-can be changed with the Login
-expiration option, giving the expiration time in hours. Setting this to 24
-for example, makes the password expire after one day. If presistent cookies are not
-desired, the Login expiration option can be set to zero, in which
-case the Remember me checkbox is not displayed.Admin user = <user list> is a list of one or more user names,
-which have admin rights. They see a button Change elogd.cfg on the
-config page by which they can edit elogd.cfg through the web. They can also modify other
-users on the Config page, change their passwords or remove them. In
-addition, the admin user(s) can delete or edit entries from other users if
-Restrict edit = 1.Login user = <user list> is a list of users who can
-log in to a specific logbook. This option can be used with a global password file. If a
-Password file is present under the [global]
-section, the registered users in that password file can log in to all logbooks. It might
-be required that only certain users can log in to certain logbooks. This can be achieved
-with the Login user option, places in each individual logbook
-section in the configuration file. Only those users listed in this statement can log in
-to the logbook where the statement is defined. This method has the advantage over the
-option of definining individual password files for individual logbooks that only one
-central password file exists. So if a user changes her/his password, this becomes then
-valid for all logbooks. If there would be individual logbook password files, one would
-have to change the password in all logbooks individually.
-
-Self register = 0|1|2|3
-
-
-Allow password change = 0|1
-
-
-Allow <command> = <user list>
-
-
-Deny <command> = <user list>
-
-
-Hosts allow = <list>
-Hosts deny = <list>
-123.213. (note the trailing '.') or .mit.edu,
-or the word All. The following rules are applied:
-
-
-elogd with the "-v" flag, in which case the rule checking is printed
-on the screen.
-Logfile = <filename> can be specified
-to log all user login/logout activities plus all successful user connections.[global] area of the
-configuration files, they are used for all logbooks. If one logs in at one logbook,
-access is automaticlly granted to all logbooks. If the password statements are in the
-individual logbook sections, one has to log in to each logbook separately.
-
-
-Email <attribute> <value> = <list>
-Use Email Subject = <string>
-Use Email From = <string>
-Use Email Heading = <string>
-Use Email Heading Edit = <string>
-Omit Email To = 0|1
-Suppress Email to users = 0|1
-Email attributes = <list>
-
-SMTP host =
- entry must be present in the [global] section
-of the configuration file. To submit an email based on an attribute value, use the statement Email <attribute> <value> =
-<list>. Whenever an entry is submitted where
-attribute is equal to value, an email
-notification is sent to the email addresses in list.
-Several mail addresses may be supplied, separated by commas. The mail addresses can
-contain attributes via the "$" substitution. If a logbook contains for
-example an attribute name which contains email names, then one can
-put $name@domain to form a valid email address.Email xxx statements may occur in a configuration
-file. If either the attribute or the value contains one or more blanks the
-string must be enclosed with quotation marks, as in: Email type
-"Normal routine" = ...Email All =
-<list> sends an email notification independent of the type and
-category. The Use Email Subject = <string> statement
-specifies which text is used as the email subject. The text can contain
-$<attribute> statements which are substituted with the
-current value of that attribute. For a full list of possible substitutions, see
-the "Subst <attribute>" option. The Use Email Heading =
-<string> specifies the text for the email heading line. Default
-is "A new entry has been submitted on [host]". The option Use
-Email Heading Edit = <string> works the same way for updated
-(edited) entries.Use Email From = <string> is used for the
-"From:" field in the email. Since more and more email servers do not
-accept invalid "From:" addresses in order to reduce spam mail, it might
-be important that a "real" email address is used in the "From:" field. By
-default, the email address of the currently logged in user is used for the
-"From:" field. If no user is logged in, or the current user has not
-specified a email address in the password database, the setting of the option
-Use Email From is used for the "From:" field. Only if
-this option is not specified, a generic address ELOG@<hostname> is
-used, which might be rejected by the SMTP server however.Omit Email To is set to 1, the To:
-field in the email is left empty instead set to the real email address of the
-recipients. This can be useful if one recipient should not see the email
-addresses of the other recipients. Suppress Email to
-users can be set to "1" if email should only be sent to the
-recipients of the Email <attribute> <value> =
-<list> statements but not to the users who have registerd for
-automatic email notification.Email attributes = <list>,
-where a subset of the attributes can be specified as well as their order.
-
-
-
-
Show text = 0|1
-
-This flag controls if logbook entries contain a body text. If an installation
-only requires attributes, this flag can be set to 0. Default is
-1.
-Enable attachments = 0|1
-
-This flag controls the attachment submission at the bottom of a message
-entry page. If this flag is 0, the attachment section is not displayed.
-This might be useful for logbooks where attachments are not used. Default
-is 1.
-Show attachments = 0|1
-
-This flag controls the display of attachments such as images on normal
-logbook pages. For logbooks with large images, this flag can be turned off,
-so that attachments are only displayed when they are clicked on. Default
-is 1.
-Summary lines = x
-
-This specifies the number of text lines displayed in a summary page. Zero displays
-no text at all. The default is 3.
-Reverse sort = 0|1
-
-If this flag is 1, all listing pages (the default page view, the result of
-a search query and the result of the "Last day" query)
-is sorted in reverse order (newest entry down to oldest). The checkbox Sort in
-reverse order on the search form gets checked by default, too. Sorting in reverse
-order can make sense if there are many pages of entries, but the ones entered last
-should be displayed on the first page. Default is 0.Search all logbooks = 0|1
-
-If this flag is 1, the search form displays the button "Search all
-logbooks". The default is 1. It might be necessary to turn this option
-off for public logbooks if there are also protected logbooks. Otherwise the
-search result would also display entries from the protected logbooks.Enable browsing = 0|1
-
-If this flag is 1, browsing (hitting the next/previous button) is enabled.
-For some rare occasions it might be necessary to disable browsing. Default is
-1.
-Filtered browsing = 0|1
-
-If this flag is 1, browsing (hitting the next/previous button) can be
-filtered by individual attributes. If the checkbox next to an attribute is checked,
-only messages with the same attribute value are displayed. Default is 0.
-Default encoding = 0|1|2
-
-This specifies the default encoding for new entries. For installations where entries
-are normally submitted as plain text, the default can be set to 1. Set to 0
-for ELCode encoding,
-to 2 for HTML encoding. The default is 0.
-Suppress default = 0|1|2|3
-
-This specifies the default state of the "Suppress Email notification" button on the
-new message entry form. For installations where normally an email notification is
-not necessary, the default can be set to 1. If an important entry is
-entered, users can then uncheck the suppress box. If this value is set to 2
-, the suppress box is not displayed at all, so that an email notification is
-always produced. If this value is set to 3, the email notification is
-always suppressed. The default is 0.
-Resubmit default = 0|1|2
-
-This specifies the default state of the "Resubmit as new entry" button on the
-edit message entry from. If this button is checked, the current message is removed
-from its current position in the database and submitted as a new message. This
-can for example be useful for applications where users want to see which records
-have been updated recently. If this value is set to 2, the resubmit box
-is not displayed at all. The default is 0.
-Resubmit replies = 0|1 If this flag is set to
-1 and an entry is resubmited as a new entry and this entry has replies,
-all replies of this entry are resubmittes as new entries as well. The default is
-0.
-Display Email recipients = 0|1
-
-If this flag is 1, the email recipients are displayed when a logbook
-entry is entered which produces an email notification. Setting this flag to 0
-suppresses this display, in case users need not see that email is being sent and to whom.
-The default is 1.
-Email Format = <n>
-
-Specifies what is sent in an email notification. <n> is the sum of following
-flags:
-
-
-
-
-So to send for example only the attributes and the URL, set <n>
-to 6. Default is 63 (send everything).
-Suppress Email on edit = 0|1
-
-If this flag is 1, no email notifications are sent for edited messages,
-only for new messages. The default is 0.
-Email Encoding = <n>
-
-Specifies in which encoding an email is sent. <n> is the sum of following
-flags:
-
-
-
-
-So to send email in plain text and full HTML, set <n>
-to 5. Some email clients have the possibility then to switch from one view
-to the other. Default is 2.
-Back to main = 0|1
-
-If this flag is 1, the "List" button takes you back to the logbook
-selection page instead to the last entry of the current logbook.
-The default is 0.
-Logout to main = 0|1
-
-If this flag is 1, the "Logout" operation takes you back to the logbook
-selection page instead to the login page.
-The default is 0.
-Restrict edit = 0|1
-
-If this flag is 1, users can only edit their own messages. The system
-checks automatically if the currently logged in user matches the user
-supplied in an author attribute via the "Preset xxxx" option.
-The default is 0.
-Expand default = 0|1|2|3
-
-This setting determines how messages are displayed in threaded mode. Following
-options are possible:
-
-
-The default is 1.
-Summary lines option.
-Hidden = 0|1
-
-If this flag is 1, the logbook is not displayed in the initial logbook selection
-page and in the logbook tabs. This can be useful for logbooks which are only accessed
-for backup or archiving and would clutter up the logbook list for the normal user. To
-access hidden logbooks, one has to enter the logbook URL directly, or from a bookmark list.
-Default is 0.
-Use Lock = 0|1
-
-If this flag is 1, a logbook entry is locked when someone edits it (clicking
-the Edit command). A locked message gets displayed with a little red sign indicating
-that the message is currently edited by someone and should not be touched. This can be
-helpful in installations where several people can edit messages. Without locking, the second
-submission of an edited message overwrites the first submission without notice. Although
-the sign gets displayed, the message can still be edited (the lock can be "stolen"),
-but it's the user's response to avoid any conflict.
-
-Since elog cannot determine if someone keeps a message very long for editing or if only the
-browser got closed, the locking can show up even if the message is not kept for editing any more.
-In that case, the message has to be edited again and submitted, to remove the origial lock.
-
-Note that logbooks accessible from the internet usually get scanned by search engines. This
-can lead to situations where the Edit link of each message is "followed" by a bot,
-resulting in all messages being locked. In those cases locking has to be turned off.
-
-Since release 2.5.4, some Javascript code has been added to avoid unwanted locks. If someone
-edits an entry, but then goes away from that page or closes the browser without submitting
-the changes, a pop-up window appears asking the user to submit the changed entry. Although
-this works for most browsers in most cases, it could be that Javascript has been turned off
-in a browser, in which case the stale locks still might appear.
-
-Default for "Use Lock" is 0.Show top groups = 0|1
-
-When using top groups, the root of the elogd server is not accessible any more, to avoid
-cases where one group can "see" the logbooks of the other groups. If this feature is
-unwanted, the flag Show top groups can be set to 1,
-in which case a list of available top groups is shown.
-Fix text = 0|1
-
-With this options the main text body can be fixed, so that it cannot be
-changed via the Edit button later. This feature can be
-useful for set-ups where some attributed must be changed later, but the
-text body should be preserved. The default is 0.
-Case sensitive search = 0|1
-
-This switch has two meanings. First, it defines the default state of the
-Case sensitive check box in the "Find" page. Second, it determines
-if the quick filters are case sensitive or not. The default is 0.
-Mode commands = 0|1
-
-If this flag is missing or set to 1, the links "Full", "Summary" and
-"Threaded" are shown on the top of the listing page. If this flag is set to
-0, these commands are hidden. This might be useful in logbooks where only
-one mode makes sense for example.
-Suppress execute default = 0|1
-
-External scripts can be called with the Execute new/edit/delete
-options. If these options are enabled, a checkbox appears which lets the user
-suppress execution of the external script. The setting of this flag determines
-the default state of this checkbox. In logbooks where a script should only be
-ocasionally executed, it could make sense to set this flag to 1.
-
-theme = <dir> option in the configuration file. Each theme can
-contain several CSSs, which can be selected with the CSS = <filename>
-option.
-class="<name>" statements.
-These classes can be found in the .../themes/default/default.css
-file and changed accordingly. For a description of all options, please consult for example the
-W3C consortium.
-
-
-
clone
-command. Assume the existing server resides at http://master.your.domain/,
-and you want to mirror this server to a new location at http://slave.your.domain/.
-You do that by installing the elog package at the slave machine, and then executing on the slave:elogd -C http://master.your.domain
elogd -v -C http://master.your.domain
-
-Mirror server = <URL-list>
-
-This statement specifies one or more mirror servers. Each URL must contain the host, port and
-possible subdirectory of the remote server, as if you would access it through your browser.
-A typical statement looks like:
-
-Mirror server = myhost.mydomain.org:8080, http://another.server.org/elog/
-
-
-The URL should not contain any logbook name, this gets added automatically. The second
-example contains a subdirectory, which is typically used if the elogd daemon runs
-under an Apache proxy.Mirror config = 0 | 1
-
-Normally, only the logbook entries are mirrored. One can also mirror the contents
-of the elogd.cfg configuration file for individual logbooks. This can be turned on
-by setting this option to 1. Default is 0.
-Only the individual logbook section is mirrored, not the [global] section. Settings
-which are specific to one server, for example the URL = statement,
-should then be kept in the [global] section, so that they are not mirrored between
-different servers.
-
-Mirror cron = Minute Hour Day Month Weekday
-
-This statement turns on periodic mirroring. The format is similar to the UNIX
-cron command. Each of the five values can either be an
-asterisk, which means all possible values, a comma-separated list or a range.
-It can be explained most easily with examples:
-
-
-
-
-Mirror cron= meaning 0 3 * * * Every night at 3:00
-30 7 1,15 * * At 7:30 every 1st and 15th of a month
-0 12 10 10 * Once a year at 12:00 on my birthday
-0 7-18 * * 1-5 Once every hour from 7:00 to 18:00 from Monday to Friday
-
-
-Valid ranges for each value are:
-
-
-
Minute 0-59
-Hour 0-23
-Day 1-31
-Month 1-12
-Weekday 0-6 with 0=Sunday, 1=Monday, etc.
-
-
-If mirroring is turned on, it is advisable to use the Logfile =
-option to turn on logging, so that one can inspect the logfile to see if the mirroring
-works correctly.
-
-Mirror user = <name>
-
-If periodic mirroring is used via the Mirror cron = statement
-and the remote logbook uses user-level access, this statement specifies the
-user name which is used to log in to the remote logbook. The password is taken from
-the local password file and has to match the password in the remote password file,
-otherwise the access is not allowed. The user name is typical the login name of
-the administrator.
-
-Mirror simulate = 0 | 1
-
-If one wants to try out mirroring without causing any harm, one can turn on this flag.
-During synchronization, entries are compared and necessary transfers are displayed,
-but not executed. Default is 0.
-
-Mirror exclude = 0 | 1
-
-By default, all logbooks are mirrored. Individual logbooks might be excluded from
-mirroring by putting Mirror exclude = 1 in their individual logbook
-section of the configuration file (Not the [global] section).
-Default is 0.
-
-Mirror server is present in the configuration file, a new
-menu option "Synchronize" appears on the elog page. Clicking on
-this menu options starts the synchronization:
-
-
-
-On the left side one sees the entry ID's. Entries which are equal locally and remotely
-are not displayed. Here are the rules for synchronization:
-
-
-
elog:123) to the
-local entries are used, since they will point afterwards to the wrong entry.
-
-
-
-
-
+...
+
+
+
+ Self register =
+ 1 in the configuration file, or by the admin user in the
+ Config page by pressing New user. When a user is logged it,
+ the entry for this user can be modified via the Config command.
+
+
+ Password file =
+ <file> in the configuration file
+ Self register = 1 in the configuration file
+ Guest menu commands entry, you have to click
+ on "Login" to get that screen.
+ Admin user = <user> into the
+ configuration file, using your login name from above
+
+
+ Attributes = Author, Email, ...
+
+
+ Subst Author = $long_name from $remote_host
+
+ Subst Email = $user_emailRemember me checkbox
+ during the login. If unchecked, the cookies expire after the current
+ browser session. If checked, they expire after 31 days by default, which
+ can be changed with the Login expiration option,
+ giving the expiration time in hours. Setting this to 24 for example,
+ makes the password expire after one day. If presistent cookies are not
+ desired, the Login expiration option can be set to
+ zero, in which case the Remember me checkbox is not
+ displayed.
+ Admin user = <user list> is a list of one
+ or more user names, which have admin rights. They see a button
+ Change elogd.cfg on the config page by which they can
+ edit elogd.cfg through the web. They can also modify other users on the
+ Config page, change their passwords or remove them.
+ In addition, the admin user(s) can delete or edit entries from other
+ users if Restrict edit = 1.
+ Login user = <user list> is a list of users
+ who can log in to a specific logbook. This option can be used with a
+ global password file. If a Password file is present
+ under the [global] section, the registered users in
+ that password file can log in to all logbooks. It might be required that
+ only certain users can log in to certain logbooks. This can be achieved
+ with the Login user option, places in each individual
+ logbook section in the configuration file. Only those users listed in
+ this statement can log in to the logbook where the statement is defined.
+ This method has the advantage over the option of definining individual
+ password files for individual logbooks that only one central password
+ file exists. So if a user changes her/his password, this becomes then
+ valid for all logbooks. If there would be individual logbook password
+ files, one would have to change the password in all logbooks
+ individually.
+
+
+ Self register = 0|1|2|3
+
+
+ Allow password change = 0|1
+
+
+ Allow <command> = <user list>
+
+
+ Deny <command> = <user list>
+
+
+ Hosts allow = <list>
+ Hosts deny = <list>
+ 123.213. (note the
+ trailing '.') or .mit.edu, or the word
+ All. The following rules are applied:
+
+
+ elogd with the "-v" flag, in which
+ case the rule checking is printed on the screen.
+ Logfile = <filename> can be
+ specified to log all user login/logout activities plus all successful
+ user connections.
+ [global]
+ area of the configuration files, they are used for all logbooks. If one
+ logs in at one logbook, access is automaticlly granted to all logbooks.
+ If the password statements are in the individual logbook sections, one
+ has to log in to each logbook separately.
+
+
+
+ Email <attribute> <value> =
+ <list>
+ Use Email Subject = <string>
+ Use Email From = <string>
+ Use Email Heading = <string>
+ Use Email Heading Edit = <string>
+ Omit Email To = 0|1
+ Suppress Email to users = 0|1
+ Email attributes = <list>
+ SMTP host = entry must be present in the
+ [global] section of the configuration file. To submit
+ an email based on an attribute value, use the statement Email
+ <attribute> <value> = <list>. Whenever an
+ entry is submitted where attribute is equal to
+ value, an email notification is sent to the email
+ addresses in list. Several mail addresses may be
+ supplied, separated by commas. The mail addresses can contain attributes
+ via the "$" substitution. If a logbook contains for example an
+ attribute name which contains email names, then one can put
+ $name@domain to form a valid email address.
+ Email xxx statements may occur in a
+ configuration file. If either the attribute or the value contains one or
+ more blanks the string must be enclosed with quotation marks, as in:
+
+
+ Email type "Normal routine" = ...
+ Email All = <list> sends an email
+ notification independent of the type and category. The Use Email
+ Subject = <string> statement specifies which text is
+ used as the email subject. The text can contain
+ $<attribute> statements which are substituted
+ with the current value of that attribute. For a full list of possible
+ substitutions, see the "Subst <attribute>" option. The
+ Use Email Heading = <string> specifies the text
+ for the email heading line. Default is "A new entry has been submitted
+ on [host]". The option Use Email Heading Edit =
+ <string> works the same way for updated (edited)
+ entries.
+ Use Email From = <string> is used
+ for the "From:" field in the email. Since more and more email
+ servers do not accept invalid "From:" addresses in order to reduce
+ spam mail, it might be important that a "real" email address is used in
+ the "From:" field. By default, the email address of the currently
+ logged in user is used for the "From:" field. If no user is logged
+ in, or the current user has not specified a email address in the password
+ database, the setting of the option Use Email From is
+ used for the "From:" field. Only if this option is not specified,
+ a generic address ELOG@<hostname> is used, which might be
+ rejected by the SMTP server however.
+ Omit Email To is set to 1, the
+ To: field in the email is left empty instead set to the real email
+ address of the recipients. This can be useful if one recipient should not
+ see the email addresses of the other recipients.
+ Suppress Email to users can be set to
+ "1" if email should only be sent to the recipients of the
+ Email <attribute> <value> = <list>
+ statements but not to the users who have registerd for automatic email
+ notification.
+ Email attributes =
+ <list>, where a subset of the attributes can be
+ specified as well as their order.
+
+
+
+
+ Show text = 0|1
+ This flag controls if logbook entries contain a body text. If an
+ installation only requires attributes, this flag can be set to
+ 0. Default is 1.
+ Enable attachments = 0|1
+ This flag controls the attachment submission at the bottom of a message
+ entry page. If this flag is 0, the attachment section is not
+ displayed. This might be useful for logbooks where attachments are not
+ used. Default is 1.
+ Show attachments = 0|1
+ This flag controls the display of attachments such as images on normal
+ logbook pages. For logbooks with large images, this flag can be turned
+ off, so that attachments are only displayed when they are clicked on.
+ Default is 1.
+ Summary lines = x
+ This specifies the number of text lines displayed in a summary page.
+ Zero displays no text at all. The default is 3.
+ Reverse sort = 0|1
+ If this flag is 1, all listing pages (the default page view, the
+ result of a search query and the result of the "Last day" query)
+ is sorted in reverse order (newest entry down to oldest). The checkbox
+ Sort in reverse order on the search form gets checked by
+ default, too. Sorting in reverse order can make sense if there are many
+ pages of entries, but the ones entered last should be displayed on the
+ first page. Default is 0.
+ Search all logbooks = 0|1
+ If this flag is 1, the search form displays the button
+ "Search all logbooks". The default is 1. It might be
+ necessary to turn this option off for public logbooks if there are also
+ protected logbooks. Otherwise the search result would also display
+ entries from the protected logbooks.
+ Enable browsing = 0|1
+ If this flag is 1, browsing (hitting the next/previous button)
+ is enabled. For some rare occasions it might be necessary to disable
+ browsing. Default is 1.
+ Filtered browsing = 0|1
+ If this flag is 1, browsing (hitting the next/previous button)
+ can be filtered by individual attributes. If the checkbox next to an
+ attribute is checked, only messages with the same attribute value are
+ displayed. Default is 0.
+ Default encoding = 0|1|2
+ This specifies the default encoding for new entries. For installations
+ where entries are normally submitted as plain text, the default can be
+ set to 1. Set to 0 for ELCode encoding, to
+ 2 for HTML encoding. The default is 0.
+ Suppress default = 0|1|2|3
+ This specifies the default state of the "Suppress Email
+ notification" button on the new message entry form. For
+ installations where normally an email notification is not necessary,
+ the default can be set to 1. If an important entry is entered,
+ users can then uncheck the suppress box. If this value is set to
+ 2 , the suppress box is not displayed at all, so that an email
+ notification is always produced. If this value is set to 3, the
+ email notification is always suppressed. The default is 0.
+ Resubmit default = 0|1|2
+ This specifies the default state of the "Resubmit as new entry"
+ button on the edit message entry from. If this button is checked, the
+ current message is removed from its current position in the database
+ and submitted as a new message. This can for example be useful for
+ applications where users want to see which records have been updated
+ recently. If this value is set to 2, the resubmit box is not
+ displayed at all. The default is 0.
+ Resubmit replies = 0|1
+ If this flag is set to 1 and an entry is resubmited as a new
+ entry and this entry has replies, all replies of this entry are
+ resubmittes as new entries as well. The default is 0.
+ Display Email recipients = 0|1
+ If this flag is 1, the email recipients are displayed when a
+ logbook entry is entered which produces an email notification. Setting
+ this flag to 0 suppresses this display, in case users need not see that
+ email is being sent and to whom. The default is 1.
+ Email Format = <n>
+ Specifies what is sent in an email notification. <n> is the sum
+ of following flags:
+
+
So to send for example only the attributes and the URL, set
+ <n> to 6. Default is 63 (send everything).
+ Suppress Email on edit = 0|1
+ If this flag is 1, no email notifications are sent for edited
+ messages, only for new messages. The default is 0.
+ Email Encoding = <n>
+ Specifies in which encoding an email is sent. <n> is the sum of
+ following flags:
+
+
So to send email in plain text and full HTML, set <n> to
+ 5. Some email clients have the possibility then to switch from
+ one view to the other. Default is 2.
+ Back to main = 0|1
+ If this flag is 1, the "List" button takes you back to
+ the logbook selection page instead to the last entry of the current
+ logbook. The default is 0.
+ Logout to main = 0|1
+ If this flag is 1, the "Logout" operation takes you back
+ to the logbook selection page instead to the login page. The default is
+ 0.
+ Restrict edit = 0|1
+ If this flag is 1, users can only edit their own messages. The
+ system checks automatically if the currently logged in user matches the
+ user supplied in an author attribute via the "Preset xxxx"
+ option. The default is 0.
+ Expand default = 0|1|2|3
+ This setting determines how messages are displayed in threaded mode.
+ Following options are possible:
+
+
The default is 1.
+ Summary lines option.
+ Hidden = 0|1
+ If this flag is 1, the logbook is not displayed in the initial
+ logbook selection page and in the logbook tabs. This can be useful for
+ logbooks which are only accessed for backup or archiving and would
+ clutter up the logbook list for the normal user. To access hidden
+ logbooks, one has to enter the logbook URL directly, or from a bookmark
+ list. Default is 0.
+ Use Lock = 0|1
+ If this flag is 1, a logbook entry is locked when someone
+ edits it (clicking the Edit command). A locked message gets
+ displayed with a little red sign indicating that the message is
+ currently edited by someone and should not be touched. This can be
+ helpful in installations where several people can edit messages.
+ Without locking, the second submission of an edited message overwrites
+ the first submission without notice. Although the sign gets displayed,
+ the message can still be edited (the lock can be "stolen"), but it's
+ the user's response to avoid any conflict.
+
+ Since elog cannot determine if someone keeps a message very long for
+ editing or if only the browser got closed, the locking can show up even
+ if the message is not kept for editing any more. In that case, the
+ message has to be edited again and submitted, to remove the origial
+ lock.
+
+ Note that logbooks accessible from the internet usually get scanned by
+ search engines. This can lead to situations where the Edit link
+ of each message is "followed" by a bot, resulting in all messages being
+ locked. In those cases locking has to be turned off.
+
+ Since release 2.5.4, some Javascript code has been added to avoid
+ unwanted locks. If someone edits an entry, but then goes away from that
+ page or closes the browser without submitting the changes, a pop-up
+ window appears asking the user to submit the changed entry. Although
+ this works for most browsers in most cases, it could be that Javascript
+ has been turned off in a browser, in which case the stale locks still
+ might appear.
+
+ Default for "Use Lock" is 0.
+ Show top groups = 0|1
+ When using top groups, the root of the elogd server is not accessible
+ any more, to avoid cases where one group can "see" the logbooks of the
+ other groups. If this feature is unwanted, the flag Show top
+ groups can be set to 1, in which case a
+ list of available top groups is shown.
+ Fix text = 0|1
+ With this options the main text body can be fixed, so that it cannot be
+ changed via the Edit button later. This feature can
+ be useful for set-ups where some attributed must be changed later, but
+ the text body should be preserved. The default is 0.
+ Case sensitive search = 0|1
+ This switch has two meanings. First, it defines the default state of
+ the Case sensitive check box in the "Find" page.
+ Second, it determines if the quick filters are case sensitive or not.
+ The default is 0.
+ Mode commands = 0|1
+ If this flag is missing or set to 1, the links "Full", "Summary"
+ and "Threaded" are shown on the top of the listing page. If this flag
+ is set to 0, these commands are hidden. This might be useful in
+ logbooks where only one mode makes sense for example.
+ Suppress execute default = 0|1
+ External scripts can be called with the Execute
+ new/edit/delete options. If these options are enabled, a
+ checkbox appears which lets the user suppress execution of the external
+ script. The setting of this flag determines the default state of this
+ checkbox. In logbooks where a script should only be ocasionally
+ executed, it could make sense to set this flag to 1.
+
+ theme = <dir> option in the configuration file.
+ Each theme can contain several CSSs, which can be selected with the
+ CSS = <filename> option.
+ class="<name>" statements. These classes can be
+ found in the .../themes/default/default.css file and
+ changed accordingly. For a description of all options, please consult for
+ example the W3C consortium.
+
+
+
+
+ clone command. Assume the existing server
+ resides at http://master.your.domain/, and you
+ want to mirror this server to a new location at
+ http://slave.your.domain/. You do that by
+ installing the elog package at the slave machine, and then executing
+ on the slave:
+
+elogd -C http://master.your.domain
+
+
+elogd -v -C http://master.your.domain
+
+
+
+ Mirror server = <URL-list>
+
+ This statement specifies one or more mirror servers. Each URL must
+ contain the host, port and possible subdirectory of the remote
+ server, as if you would access it through your browser. A typical
+ statement looks like:
+
+ Mirror server = myhost.mydomain.org:8080,
+ http://another.server.org/elog/
+
+ The URL should not contain any logbook name, this gets added
+ automatically. The second example contains a subdirectory, which is
+ typically used if the elogd daemon runs under an Apache proxy.
+ Mirror config = 0 | 1
+
+ Normally, only the logbook entries are mirrored. One can also
+ mirror the contents of the elogd.cfg configuration file for
+ individual logbooks. This can be turned on by setting this option
+ to 1. Default is 0. Only
+ the individual logbook section is mirrored, not the [global]
+ section. Settings which are specific to one server, for example the
+ URL = statement, should then be kept in the
+ [global] section, so that they are not mirrored between different
+ servers.
+
+ Mirror cron = Minute Hour Day Month Weekday
+
+ This statement turns on periodic mirroring. The format is similar
+ to the UNIX cron command. Each of the five
+ values can either be an asterisk, which means all possible values,
+ a comma-separated list or a range. It can be explained most easily
+ with examples:
+
+
+
+
+
+ Mirror cron=
+
+
+ meaning
+
+
+
+
+ 0 3 * * *
+
+
+ Every night at 3:00
+
+
+
+
+ 30 7 1,15 * *
+
+
+ At 7:30 every 1st and 15th of a month
+
+
+
+
+ 0 12 10 10 *
+
+
+ Once a year at 12:00 on my birthday
+
+
+
+
+ 0 7-18 * * 1-5
+
+
+ Once every hour from 7:00 to 18:00 from Monday to Friday
+
+
+
+ Valid ranges for each value are:
+
+
+
+
+
+ Minute
+
+
+ 0-59
+
+
+
+
+ Hour
+
+
+ 0-23
+
+
+
+
+ Day
+
+
+ 1-31
+
+
+
+
+ Month
+
+
+ 1-12
+
+
+
+
+ Weekday
+
+
+ 0-6 with 0=Sunday, 1=Monday, etc.
+
+
+
+ If mirroring is turned on, it is advisable to use the
+ Logfile = option to turn on logging, so that
+ one can inspect the logfile to see if the mirroring works
+ correctly.
+
+ Mirror user = <name>
+
+ If periodic mirroring is used via the Mirror cron
+ = statement and the remote logbook uses user-level
+ access, this statement specifies the user name which is used to log
+ in to the remote logbook. The password is taken from the local
+ password file and has to match the password in the remote password
+ file, otherwise the access is not allowed. The user name is typical
+ the login name of the administrator.
+
+ Mirror simulate = 0 | 1
+
+ If one wants to try out mirroring without causing any harm, one can
+ turn on this flag. During synchronization, entries are compared and
+ necessary transfers are displayed, but not executed. Default is
+ 0.
+
+ Mirror exclude = 0 | 1
+
+ By default, all logbooks are mirrored. Individual logbooks might be
+ excluded from mirroring by putting Mirror exclude =
+ 1 in their individual logbook section of the
+ configuration file (Not the [global] section). Default is
+ 0.
+ Mirror server is present in the
+ configuration file, a new menu option "Synchronize"
+ appears on the elog page. Clicking on this menu options starts the
+ synchronization:
+
+ 
+
+ On the left side one sees the entry ID's. Entries which are equal locally
+ and remotely are not displayed. Here are the rules for
+ synchronization:
+
+
+
+ elog:123) to the local entries are used, since they
+ will point afterwards to the wrong entry.
+
+
+
+
diff --git a/doc/download.html b/doc/download.html
index d5e4a748..d6076ce9 100755
--- a/doc/download.html
+++ b/doc/download.html
@@ -29,8 +29,8 @@ containing bug fixes or some new and not yet completely debugged code. This
is usually the case if some user asks for some new features, which are then
implemented and sent to the user for testing. The minor releases are named
x.y.z-r where r is the release number.
-A web access to the
-source code contains the complete development history of ELOG. To check out the complete
+A web access
+to the source code contains the complete development history of ELOG. To check out the complete
Subversion tree, use:
svn checkout svn+ssh://svn@savannah.psi.ch/afs/psi.ch/project/meg/svn/elog/trunk elog
diff --git a/doc/elog.css b/doc/elog.css
index 7c653a5e..31771a61 100755
--- a/doc/elog.css
+++ b/doc/elog.css
@@ -2,7 +2,6 @@
.title { padding: 5px 10px;
background-color: rgb(72, 96, 144);
- font-family: Verdana,Arial,Helvetica,Sans-Serif;
font-size: x-large;
color: white;
text-align: center;
@@ -10,19 +9,17 @@
.version { padding: 5px 10px;
color: rgb(72, 96, 144);
- font-family: Verdana,Arial,Helvetica,Sans-Serif;
text-align: center;
font-weight: bold;
}
- .Sub { font-family: Verdana,Arial,Helvetica,Sans-Serif;
+ .Sub {
font-size: medium;
text-align: center;
}
.menu { padding: 5px 10px;
background-color: rgb(72, 96, 144);
- font-family: Verdana,Arial,Helvetica,Sans-Serif;
font-size: medium;
color: white;
text-align: center;
@@ -34,7 +31,6 @@
.section { padding: 5px 10px;
background-color: rgb(72, 96, 144);
- font-family: Verdana,Arial,Helvetica,Sans-Serif;
font-size: large;
color: white;
text-align: left;
@@ -42,13 +38,17 @@
.footer { padding: 5px 10px;
background-color: rgb(72, 96, 144);
- font-family: Verdana,Arial,Helvetica,Sans-Serif;
font-size: small;
color: white;
text-align: left;
}
- p { margin-left: 10px;
+ body {
+ font-family: Verdana,Arial,Helvetica,Sans-Serif;
+ }
+
+ p {
+ margin-left: 10px;
margin-right: 10px;
}
diff --git a/src/elogd.c b/src/elogd.c
index aaa00f92..751d2b3c 100755
--- a/src/elogd.c
+++ b/src/elogd.c
@@ -251,6 +251,7 @@ char author_list[MAX_N_LIST][NAME_LENGTH] = {
#define AF_TIME (1<<10)
#define AF_NUMERIC (1<<11)
#define AF_USERLIST (1<<12)
+#define AF_HIDDEN (1<<13)
/* attribute format flags */
#define AFF_SAME_LINE 1
@@ -552,6 +553,32 @@ size_t my_strftime(char *s, size_t max, const char *fmt, const struct tm * tm)
return strftime(s, max, fmt, tm);
}
+/* signal save read function */
+int my_read(int fh, void *buffer, unsigned int bytes)
+{
+#ifdef OS_UNIX
+ int i, n = 0;
+
+ do {
+ i = read(fh, buffer+n, bytes-n);
+
+ /* don't return if an alarm signal was cought */
+ if (i == -1 && errno == EINTR)
+ continue;
+
+ if (i == -1)
+ return -1;
+
+ n += i;
+
+ } while (n < bytes);
+#else
+ return read(fh, buffer, bytes);
+#endif
+
+ return 0;
+}
+
/*---- Compose RFC2822 compliant date ---*/
void get_rfc2822_date(char *date, int size, time_t ltime)
@@ -4041,7 +4068,7 @@ int el_retrieve(LOGBOOK * lbs,
message = malloc(TEXT_SIZE + 1000);
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
- i = read(fh, message, TEXT_SIZE + 1000 - 1);
+ i = my_read(fh, message, TEXT_SIZE + 1000 - 1);
if (i <= 0) {
free(message);
close(fh);
@@ -4260,7 +4287,7 @@ int el_retrieve_attachment(LOGBOOK * lbs, int message_id, int n, char name[MAX_P
}
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
- i = read(fh, message, sizeof(message) - 1);
+ i = my_read(fh, message, sizeof(message) - 1);
if (i <= 0) {
close(fh);
return EL_FILE_ERROR;
@@ -4381,7 +4408,7 @@ int el_submit(LOGBOOK * lbs, int message_id, BOOL bedit,
}
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
- i = read(fh, message, TEXT_SIZE + 100);
+ i = my_read(fh, message, TEXT_SIZE + 100);
message[i] = 0;
/* check for valid message */
@@ -4430,7 +4457,7 @@ int el_submit(LOGBOOK * lbs, int message_id, BOOL bedit,
buffer = xmalloc(tail_size);
lseek(fh, lbs->el_index[index].offset + size, SEEK_SET);
- n = read(fh, buffer, tail_size);
+ n = my_read(fh, buffer, tail_size);
}
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
} else {
@@ -4679,7 +4706,7 @@ int el_delete_message(LOGBOOK * lbs, int message_id,
message = xmalloc(TEXT_SIZE + 1000);
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
- i = read(fh, message, TEXT_SIZE + 1000 - 1);
+ i = my_read(fh, message, TEXT_SIZE + 1000 - 1);
if (i <= 0) {
xfree(message);
close(fh);
@@ -4756,7 +4783,7 @@ int el_delete_message(LOGBOOK * lbs, int message_id,
buffer = xmalloc(tail_size);
lseek(fh, lbs->el_index[index].offset + size, SEEK_SET);
- n = read(fh, buffer, tail_size);
+ n = my_read(fh, buffer, tail_size);
}
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
@@ -6185,139 +6212,154 @@ void set_location(LOGBOOK * lbs, char *rel_path)
char str[NAME_LENGTH], group[NAME_LENGTH], list[NAME_LENGTH], *p;
int i;
- /* if path contains http(s), go directly there */
- if (strncmp(rel_path, "http://", 7) == 0) {
- rsputs("Location: ");
- rsputs(rel_path);
- } else if (strncmp(rel_path, "https://", 8) == 0) {
- rsputs("Location: ");
- rsputs(rel_path);
- } else {
+ if (getcfg(lbs->name, "Relative redirect", str, sizeof(str)) &&
+ atoi(str) == 1) {
- /* check for URL options */
- str[0] = 0;
- if (lbs)
- getcfg(lbs->name, "URL", str, sizeof(str));
+ if (rel_path[0])
+ strlcpy(str, rel_path, sizeof(str));
else
- getcfg("global", "URL", str, sizeof(str));
+ strlcpy(str, ".", sizeof(str));
- if (str[0] == 0) {
+ rsputs("Location: ");
+ rsputs(str);
- /* get redirection from referer and host */
-
- if (referer[0]) {
- strlcpy(str, referer, sizeof(str));
-
- /* strip any parameter */
- if (strchr(str, '?'))
- *strchr(str, '?') = 0;
-
- /* strip rightmost '/' */
- if (str[strlen(str) - 1] == '/')
- str[strlen(str) - 1] = 0;
-
- /* extract last subdir */
- p = str + strlen(str);
- while (p > str && *p != '/')
- p--;
- if (*p == '/')
- p++;
-
- /* if last subdir equals any logbook name, strip it */
- for (i = 0; lb_list[i].name[0]; i++)
- if (stricmp(p, lb_list[i].name_enc) == 0) {
- *p = 0;
- break;
- }
-
- /* if last subdir equals any group, strip it */
- sprintf(group, "Group %s", p);
- if (getcfg("global", group, list, sizeof(list)))
- *p = 0;
-
- /* if last subdir equals any top group, strip it */
- sprintf(group, "Top group %s", p);
- if (getcfg("global", group, list, sizeof(list)))
- *p = 0;
-
- } else {
- /* assemble absolute path from host name and port */
- sprintf(str, "http://%s", http_host);
- if (elog_tcp_port != 80 && strchr(str, ':') == NULL)
- sprintf(str + strlen(str), ":%d", elog_tcp_port);
- strlcat(str, "/", sizeof(str));
- }
-
- /* add trailing '/' if not present */
- if (str[strlen(str) - 1] != '/')
- strlcat(str, "/", sizeof(str));
-
- /* add top group if existing and not logbook */
- if (!lbs && getcfg_topgroup()) {
- strlcat(str, getcfg_topgroup(), sizeof(str));
- strlcat(str, "/", sizeof(str));
- }
-
- if (strncmp(rel_path, "../", 3) == 0)
- strlcat(str, rel_path + 3, sizeof(str));
- else if (strcmp(rel_path, ".") == 0) {
- if (lbs)
- strlcat(str, lbs->name_enc, sizeof(str));
- } else if (rel_path[0] == '/')
- strlcat(str, rel_path + 1, sizeof(str));
- else {
- if (lbs) {
- strlcat(str, lbs->name_enc, sizeof(str));
- strlcat(str, "/", sizeof(str));
- strlcat(str, rel_path, sizeof(str));
- } else
- strlcat(str, rel_path, sizeof(str));
- }
+ } else {
+ /* Absolute redirect */
+ /* if path contains http(s), go directly there */
+ if (strncmp(rel_path, "http://", 7) == 0) {
rsputs("Location: ");
- rsputs(str);
-
+ rsputs(rel_path);
+ } else if (strncmp(rel_path, "https://", 8) == 0) {
+ rsputs("Location: ");
+ rsputs(rel_path);
} else {
- /* use redirection via URL */
+ /* check for URL options */
+ str[0] = 0;
+ if (lbs)
+ getcfg(lbs->name, "URL", str, sizeof(str));
+ else
+ getcfg("global", "URL", str, sizeof(str));
- /* if HTTP request comes from localhost, use localhost as
- absolute link (needed if running on DSL at home) */
- if (!str[0] && strstr(http_host, "localhost")) {
- strlcpy(str, "http://localhost", sizeof(str));
- if (elog_tcp_port != 80)
- sprintf(str + strlen(str), ":%d", elog_tcp_port);
- strlcat(str, "/", sizeof(str));
- }
+ if (str[0] == 0) {
- /* add trailing '/' if not present */
- if (str[strlen(str) - 1] != '/')
- strlcat(str, "/", sizeof(str));
+ /* get redirection from referer and host */
- /* add top group if existing and not logbook */
- if (!lbs && getcfg_topgroup()) {
- strlcat(str, getcfg_topgroup(), sizeof(str));
- strlcat(str, "/", sizeof(str));
- }
+ if (referer[0]) {
+ strlcpy(str, referer, sizeof(str));
- if (strncmp(rel_path, "../", 3) == 0)
- strlcat(str, rel_path + 3, sizeof(str));
- else if (strcmp(rel_path, ".") == 0) {
- if (lbs)
- strlcat(str, lbs->name_enc, sizeof(str));
- } else if (rel_path[0] == '/')
- strlcat(str, rel_path + 1, sizeof(str));
- else {
- if (lbs) {
- strlcat(str, lbs->name_enc, sizeof(str));
+ /* strip any parameter */
+ if (strchr(str, '?'))
+ *strchr(str, '?') = 0;
+
+ /* strip rightmost '/' */
+ if (str[strlen(str) - 1] == '/')
+ str[strlen(str) - 1] = 0;
+
+ /* extract last subdir */
+ p = str + strlen(str);
+ while (p > str && *p != '/')
+ p--;
+ if (*p == '/')
+ p++;
+
+ /* if last subdir equals any logbook name, strip it */
+ for (i = 0; lb_list[i].name[0]; i++)
+ if (stricmp(p, lb_list[i].name_enc) == 0) {
+ *p = 0;
+ break;
+ }
+
+ /* if last subdir equals any group, strip it */
+ sprintf(group, "Group %s", p);
+ if (getcfg("global", group, list, sizeof(list)))
+ *p = 0;
+
+ /* if last subdir equals any top group, strip it */
+ sprintf(group, "Top group %s", p);
+ if (getcfg("global", group, list, sizeof(list)))
+ *p = 0;
+
+ } else {
+ /* assemble absolute path from host name and port */
+ sprintf(str, "http://%s", http_host);
+ if (elog_tcp_port != 80 && strchr(str, ':') == NULL)
+ sprintf(str + strlen(str), ":%d", elog_tcp_port);
strlcat(str, "/", sizeof(str));
- strlcat(str, rel_path, sizeof(str));
- } else
- strlcat(str, rel_path, sizeof(str));
- }
+ }
- rsputs("Location: ");
- rsputs(str);
+ /* add trailing '/' if not present */
+ if (str[strlen(str) - 1] != '/')
+ strlcat(str, "/", sizeof(str));
+
+ /* add top group if existing and not logbook */
+ if (!lbs && getcfg_topgroup()) {
+ strlcat(str, getcfg_topgroup(), sizeof(str));
+ strlcat(str, "/", sizeof(str));
+ }
+
+ if (strncmp(rel_path, "../", 3) == 0)
+ strlcat(str, rel_path + 3, sizeof(str));
+ else if (strcmp(rel_path, ".") == 0) {
+ if (lbs)
+ strlcat(str, lbs->name_enc, sizeof(str));
+ } else if (rel_path[0] == '/')
+ strlcat(str, rel_path + 1, sizeof(str));
+ else {
+ if (lbs) {
+ strlcat(str, lbs->name_enc, sizeof(str));
+ strlcat(str, "/", sizeof(str));
+ strlcat(str, rel_path, sizeof(str));
+ } else
+ strlcat(str, rel_path, sizeof(str));
+ }
+
+ rsputs("Location: ");
+ rsputs(str);
+
+ } else {
+
+ /* use redirection via URL */
+
+ /* if HTTP request comes from localhost, use localhost as
+ absolute link (needed if running on DSL at home) */
+ if (!str[0] && strstr(http_host, "localhost")) {
+ strlcpy(str, "http://localhost", sizeof(str));
+ if (elog_tcp_port != 80)
+ sprintf(str + strlen(str), ":%d", elog_tcp_port);
+ strlcat(str, "/", sizeof(str));
+ }
+
+ /* add trailing '/' if not present */
+ if (str[strlen(str) - 1] != '/')
+ strlcat(str, "/", sizeof(str));
+
+ /* add top group if existing and not logbook */
+ if (!lbs && getcfg_topgroup()) {
+ strlcat(str, getcfg_topgroup(), sizeof(str));
+ strlcat(str, "/", sizeof(str));
+ }
+
+ if (strncmp(rel_path, "../", 3) == 0)
+ strlcat(str, rel_path + 3, sizeof(str));
+ else if (strcmp(rel_path, ".") == 0) {
+ if (lbs)
+ strlcat(str, lbs->name_enc, sizeof(str));
+ } else if (rel_path[0] == '/')
+ strlcat(str, rel_path + 1, sizeof(str));
+ else {
+ if (lbs) {
+ strlcat(str, lbs->name_enc, sizeof(str));
+ strlcat(str, "/", sizeof(str));
+ strlcat(str, rel_path, sizeof(str));
+ } else
+ strlcat(str, rel_path, sizeof(str));
+ }
+
+ rsputs("Location: ");
+ rsputs(str);
+ }
}
}
@@ -6575,6 +6617,15 @@ and attr_flags arrays */
attr_flags[j] |= AF_FIXED_REPLY;
}
+ /* check if hidden attribute */
+ getcfg(logbook, "Hidden Attributes", list, sizeof(list));
+ m = strbreak(list, tmp_list, MAX_N_ATTR, ",");
+ for (i = 0; i < m; i++) {
+ for (j = 0; j < n; j++)
+ if (strieq(attr_list[j], tmp_list[i]))
+ attr_flags[j] |= AF_HIDDEN;
+ }
+
/* check for extendable options */
getcfg(logbook, "Extendable Options", list, sizeof(list));
m = strbreak(list, tmp_list, MAX_N_ATTR, ",");
@@ -7224,8 +7275,8 @@ void show_top_text(LOGBOOK * lbs)
void show_bottom_text(LOGBOOK * lbs)
{
- char str[NAME_LENGTH];
- int size;
+ char str[NAME_LENGTH], slist[20][NAME_LENGTH], svalue[20][NAME_LENGTH];
+ int i, size;
if (getcfg(lbs->name, "bottom text", str, sizeof(str))) {
FILE *f;
@@ -7246,14 +7297,22 @@ void show_bottom_text(LOGBOOK * lbs)
size = TELL(fileno(f));
fseek(f, 0, SEEK_SET);
- buf = xmalloc(size + 1);
+ buf = xmalloc(size + 100);
fread(buf, 1, size, f);
buf[size] = 0;
fclose(f);
+ i = build_subst_list(lbs, slist, svalue, NULL, TRUE);
+ strsubst_list(buf, size+100, slist, svalue, i);
+
rsputs(buf);
- } else
+ xfree(buf);
+ } else {
+ i = build_subst_list(lbs, slist, svalue, NULL, TRUE);
+ strsubst_list(str, sizeof(str), slist, svalue, i);
+
rsputs(str);
+ }
}
} else
/* add little logo */
@@ -7661,6 +7720,13 @@ int build_subst_list(LOGBOOK * lbs, char list[][NAME_LENGTH], char value[][NAME_
sprintf(str, "%d", (int) t);
strcpy(value[i++], str);
+ /* add ELOG version and revision */
+ strcpy(list[i], "version");
+ strcpy(value[i++], VERSION);
+
+ strcpy(list[i], "revision");
+ sprintf(value[i++], "%d", atoi(svn_revision + 13));
+
return i;
}
@@ -8919,6 +8985,10 @@ void show_edit_form(LOGBOOK * lbs, int message_id, BOOL breply, BOOL bedit, BOOL
index = attr_index[aindex];
+ /* if attribute is hidden, skip it */
+ if (attr_flags[index] & AF_HIDDEN)
+ continue;
+
strcpy(class_name, "attribname");
strcpy(class_value, "attribvalue");
input_size = 80;
@@ -9973,7 +10043,7 @@ void show_find_form(LOGBOOK * lbs)
if (i > 2) {
if (!getcfg(lbs->name, "Search all logbooks", str, sizeof(str)) || atoi(str) == 1) {
- rsprintf("\n");
+ rsprintf("");
rsprintf("
\n", loc("Search all logbooks"));
}
}
@@ -12081,7 +12151,7 @@ int show_download_page(LOGBOOK * lbs, char *path)
return EL_FILE_ERROR;
lseek(fh, lbs->el_index[index].offset, SEEK_SET);
- i = read(fh, message, sizeof(message) - 1);
+ i = my_read(fh, message, sizeof(message) - 1);
if (i <= 0) {
close(fh);
return EL_FILE_ERROR;
@@ -14488,7 +14558,7 @@ void display_line(LOGBOOK * lbs, int message_id, int number, char *mode,
ref[0] = 0;
if (absolute_link)
compose_base_url(lbs, ref, sizeof(ref));
- sprintf(ref + strlen(ref), "%d", message_id);
+ sprintf(ref + strlen(ref), "../%s/%d", lbs->name_enc, message_id);
if (strieq(mode, "Summary")) {
if (highlight_mid == message_id) {
@@ -17997,7 +18067,7 @@ void format_email_attachments(LOGBOOK * lbs, int message_id, int attachment_type
fh = open(file_name, O_RDONLY | O_BINARY);
if (fh > 0) {
do {
- n = read(fh, buffer, 45);
+ n = my_read(fh, buffer, 45);
if (n <= 0)
break;
@@ -20638,7 +20708,7 @@ BOOL convert_password_file(char *file_name)
lseek(fh, 0, SEEK_SET);
buf = malloc(len + 1);
assert(buf);
- i = read(fh, buf, len);
+ i = my_read(fh, buf, len);
buf[i] = 0;
close(fh);
@@ -21142,7 +21212,6 @@ BOOL check_user_password(LOGBOOK * lbs, char *user, char *password, char *redir)
if (user == NULL)
status = 1;
else {
-
status = get_user_line(lbs, user, upwd, full_name, email, NULL, NULL);
if (status == 1 && user[0])
@@ -24378,7 +24447,7 @@ int ss_getchar(BOOL reset)
}
memset(c, 0, 3);
- i = read(fd, c, 1);
+ i = my_read(fd, c, 1);
if (i == 0)
return 0;
@@ -24524,7 +24593,7 @@ void create_password(char *logbook, char *name, char *pwd)
length = lseek(fh, 0, SEEK_END);
lseek(fh, 0, SEEK_SET);
cfgbuffer = xmalloc(length + 1);
- length = read(fh, cfgbuffer, length);
+ length = my_read(fh, cfgbuffer, length);
cfgbuffer[length] = 0;
close(fh);
fh = open(config_file, O_TRUNC | O_WRONLY, 0640);