<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7651.59">
<TITLE>Re: [hobbit] Changing the default 48h,12d,48d,576d period for graph display ?</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->

<P><FONT SIZE=2>In future releases, could this become a configuration option or must it stay hardcodes in the source code?<BR>
<BR>
--------------------------<BR>
Thomas Kern<BR>
301-903-2211<BR>
<BR>
<BR>
----- Original Message -----<BR>
From: henrik@hswn.dk <henrik@hswn.dk><BR>
To: hobbit@hswn.dk <hobbit@hswn.dk><BR>
Sent: Tue Mar 06 10:45:59 2007<BR>
Subject: Re: [hobbit] Changing the default 48h,12d,48d,576d period for graph display ?<BR>
<BR>
On Tue, Mar 06, 2007 at 04:40:45PM +0100, Beau Olivier wrote:<BR>
><BR>
> I'ld like to change the default period for graph display:<BR>
> by default hobbbit displays trends with 4 graphs (48h,12d,48d,576d<BR>
> periods)<BR>
> -> It is possible change it to 48h,7d,30d,365d for example ?<BR>
<BR>
It isn't configurable, but in the hobbit-4.2.0/web/hobbitgraph.c file<BR>
near the top of the file you'll find these lines:<BR>
<BR>
  #define HOUR_GRAPH  "e-48h"<BR>
  #define DAY_GRAPH   "e-12d"<BR>
  #define WEEK_GRAPH  "e-48d"<BR>
  #define MONTH_GRAPH "e-576d"<BR>
<BR>
Change them to suit you. Then search that same file for the HOUR_GRAPH<BR>
etc. further down; you'll find 1 place where each is used like this:<BR>
<BR>
  period = HOUR_GRAPH;<BR>
  persecs = 48*60*60;<BR>
<BR>
and you need to change that "persecs" calculation also for all 4 graph<BR>
types.<BR>
<BR>
Then run "make" (from the hobbit-4.2.0 directory) and "make install"<BR>
(or just copy the "web/hobbitgraph.cgi" file to your ~hobbit/server/bin/<BR>
directory).<BR>
<BR>
<BR>
Henrik<BR>
<BR>
<BR>
To unsubscribe from the hobbit list, send an e-mail to<BR>
hobbit-unsubscribe@hswn.dk<BR>
<BR>
<BR>
<BR>
</FONT>
</P>

</BODY>
</HTML>