diff --git a/doc/config.html b/doc/config.html
index e94af5b8..48060644 100755
--- a/doc/config.html
+++ b/doc/config.html
@@ -2574,6 +2574,11 @@ Options Location = Main Building{a}, New Building{b}, Old Building{c}
to the logbook selection page instead to the login page. The default is
0.
+
+ Logout to URL = <URL>
+ If this URL is set, the "Logout" operation takes you to
+ a specific web page specified in the URL.
+
List after submit = 0|1
If this flag is 1, the list page is shown after the
diff --git a/src/elogd.c b/src/elogd.c
index ee1bfaad..cb6735ad 100755
--- a/src/elogd.c
+++ b/src/elogd.c
@@ -28071,6 +28071,9 @@ void interprete(char *lbook, char *path)
if (getcfg(lbs->name, "Logout to main", str, sizeof(str)) && atoi(str) == 1) {
sprintf(str, "../");
setparam("redir", str);
+ } else {
+ if (getcfg(lbs->name, "Logout to URL", str, sizeof(str)))
+ setparam("redir", str);
}
set_sid_cookie(lbs, "", "");
sid_remove(getparam("sid"));