From 9032de4986ad6d54f1a064ded2681686d62623a2 Mon Sep 17 00:00:00 2001 From: Thomas Porzelt Date: Wed, 16 Sep 2009 13:38:23 +0200 Subject: [PATCH] [mod_status] Hide main/runtime links and version if 'short' option is set --- src/modules/mod_status.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/modules/mod_status.c b/src/modules/mod_status.c index 9e9f5d2..9378e8e 100644 --- a/src/modules/mod_status.c +++ b/src/modules/mod_status.c @@ -56,6 +56,13 @@ static const gchar html_top[] = " Started at: %s\n" " Version: " PACKAGE_VERSION " (" __DATE__ " " __TIME__ ")\n" " \n"; +static const gchar html_top_short[] = + "
Lighttpd Server Status
\n" + "
\n" + " Hostname: %s" + " Uptime: %s\n" + " Started at: %s\n" + "
\n"; static const gchar html_worker_th[] = " \n" " \n" @@ -403,7 +410,8 @@ static void status_collect_cb(gpointer cbdata, gpointer fdata, GPtrArray *result )); li_counter_format((guint64)(CUR_TS(vr->wrk) - vr->wrk->srv->started), COUNTER_TIME, tmpstr); - g_string_append_printf(html, html_top, + + g_string_append_printf(html, job->short_info ? html_top_short : html_top, vr->request.uri.host->str, tmpstr->str, vr->wrk->srv->started_str->str