I wonder if it would be possible on the All Non Green View to have instead of gifs how long the service has been in that state with the relevant colour.
Thanks.
In <BAY145-w41B73E3F0C745A39BDA0C6CFFF0 at phx.gbl> James Isolder <isolderj at hotmail.com> writes:
I wonder if it would be possible on the All Non Green View to have instead = of gifs how long the service has been in that state with the relevant colou= r.
That information is available if you let your mouse "hover" over the status icon. It is possible to change from showing the status icon to showing the duration of the latest status - I've included a small patch against 4.3.0-RC1 that does this (on the "All non-green" and the "Critical systems" pages, and only for red/yellow status). But I don't think it is something that I would want generally. Regards, Henrik Index: xymongen/pagegen.c =================================================================== --- xymongen/pagegen.c (revision 6626) +++ xymongen/pagegen.c (working copy) @@ -53,6 +53,7 @@ int critonlyreds = 0; int wantrss = 0; int nongreencolors = ((1 << COL_RED) | (1 << COL_YELLOW) | (1 << COL_PURPLE)); +int showstatusduration = 1; /* Format strings for htaccess files */ char *htaccess = NULL; @@ -471,10 +472,17 @@ do_rss_item(rssoutput, h, e); } - fprintf(output, "<IMG SRC=\"%s/%s\" ALT=\"%s\" TITLE=\"%s\" HEIGHT=\"%s\" WIDTH=\"%s\" BORDER=0></A>", - skin, dotgiffilename(e->color, e->acked, e->oldage), - htmlalttag, htmlalttag, - xgetenv("DOTHEIGHT"), xgetenv("DOTWIDTH")); + if (showstatusduration && ((e->color == COL_RED) || (e->color == COL_YELLOW)) && (pagetype != PAGE_NORMAL)) { + fprintf(output, "<font color=%s>%s</font>", colorname(e->color), e->age); + } + else { + fprintf(output, "<IMG SRC=\"%s/%s\" ALT=\"%s\" TITLE=\"%s\" HEIGHT=\"%s\" WIDTH=\"%s\" BORDER=0>", + skin, dotgiffilename(e->color, e->acked, e->oldage), + htmlalttag, htmlalttag, + xgetenv("DOTHEIGHT"), xgetenv("DOTWIDTH")); + } + + fprintf(output, "</A>"); } else { /* Report format output */
Henrik Størner <mailto:henrik at hswn.dk> wrote:
In <BAY145-w41B73E3F0C745A39BDA0C6CFFF0 at phx.gbl> James Isolder <isolderj at hotmail.com> writes:
I wonder if it would be possible on the All Non Green View to have instead = of gifs how long the service has been in that state with the relevant colou= r.
That information is available if you let your mouse "hover" over the status icon.
It is possible to change from showing the status icon to showing the duration of the latest status - I've included a small patch against 4.3.0-RC1 that does this (on the "All non-green" and the "Critical systems" pages, and only for red/yellow status). But I don't think it is something that I would want generally.
Regards, Henrik
Hmm, this display actually looks quite useful (using my imagination)! But ideally it would not be something compiled in, but available via clicking a button, probably using CSS (http://www.thesitewizard.com/javascripts/change-style-sheets.shtml), a bit like it is possible to change the size of text on some news pages by clicking on a couple of buttons on the web page, or other sites where it is possible to change the 'theme' or skin. I imagine this would not be too difficult to do (if the page used CSS already) as all the information already exists in the html.
Regards,
SebA
SebA <mailto:spa at syntec.co.uk> wrote:
Henrik Størner <mailto:henrik at hswn.dk> wrote:
In <BAY145-w41B73E3F0C745A39BDA0C6CFFF0 at phx.gbl> James Isolder <isolderj at hotmail.com> writes:
I wonder if it would be possible on the All Non Green View to have instead = of gifs how long the service has been in that state with the relevant colou= r.
That information is available if you let your mouse "hover" over the status icon.
It is possible to change from showing the status icon to showing the duration of the latest status - I've included a small patch against 4.3.0-RC1 that does this (on the "All non-green" and the "Critical systems" pages, and only for red/yellow status). But I don't think it is something that I would want generally.
Regards, Henrik
Hmm, this display actually looks quite useful (using my imagination)! But ideally it would not be something compiled in, but available via clicking a button, probably using CSS (http://www.thesitewizard.com/javascripts/change-style-sheets. shtml), a bit like it is possible to change the size of text on some news pages by clicking on a couple of buttons on the web page, or other sites where it is possible to change the 'theme' or skin. I imagine this would not be too difficult to do (if the page used CSS already) as all the information already exists in the html.
Regards,
SebA
Actually, the above link uses JavaScript to make the CSS style you chose saved in a cookie for a day. A simpler version, using just CSS, is given here, although it does not save your preference: http://www.thesitewizard.com/css/switch-alternate-css-styles.shtml It is also not so obvious how to use it (as the buttons are in the browser and not the page), and it is not supported in IE7 or Safari.
Regards,
SebA
Ok So I pulled the 430 and applied the patch and installed it on a test server to see what it would looks like how do I now enable the changed status icon.
Thanks.
From: spa at syntec.co.uk To: xymon at xymon.com Date: Wed, 26 Jan 2011 14:59:37 +0000 Subject: RE: [xymon] Hobbit WebPage Question
Henrik Størner <mailto:henrik at hswn.dk> wrote:
In <BAY145-w41B73E3F0C745A39BDA0C6CFFF0 at phx.gbl> James Isolder <isolderj at hotmail.com> writes:
I wonder if it would be possible on the All Non Green View to have instead = of gifs how long the service has been in that state with the relevant colou= r.
That information is available if you let your mouse "hover" over the status icon.
It is possible to change from showing the status icon to showing the duration of the latest status - I've included a small patch against 4.3.0-RC1 that does this (on the "All non-green" and the "Critical systems" pages, and only for red/yellow status). But I don't think it is something that I would want generally.
Regards, Henrik
Hmm, this display actually looks quite useful (using my imagination)! But ideally it would not be something compiled in, but available via clicking a button, probably using CSS (http://www.thesitewizard.com/javascripts/change-style-sheets.shtml), a bit like it is possible to change the size of text on some news pages by clicking on a couple of buttons on the web page, or other sites where it is possible to change the 'theme' or skin. I imagine this would not be too difficult to do (if the page used CSS already) as all the information already exists in the html.
Regards,
SebA
To unsubscribe from the xymon list, send an e-mail to xymon-unsubscribe at xymon.com
participants (3)
-
henrik@hswn.dk
-
isolderj@hotmail.com
-
spa@syntec.co.uk