Lazydays templates
[torrus-plus.git] / src / templates / lazydays / iframe-rrd.html
blob78b2077cdf1db3c89b458df9c1a70db92fe5c5ff
1 [%# Minimalistic HTML to include into an iframe %]
2 [% PROCESS 'html-incblocks.txt' %]
3 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
4 "http://www.w3.org/TR/html4/strict.dtd">
5 <HTML>
6 <!-- Torrus Copyright (c) 2003-2011 Stanislav Sinyagin -->
7 <HEAD>
8 <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
9 <STYLE type="text/css" media="all">
10 BODY {
11 background-color : white;
12 color : #333;
13 font-family : verdana, arial, helvetica, sans-serif;
14 font-size : 11px;
15 margin : 0;
16 padding-bottom : 0;
17 padding-left : 0;
18 padding-right : 0;
19 padding-top : 0;
22 *.Content {
23 display : block;
24 float : left;
25 margin-bottom : 20px;
26 margin-left : 0px;
27 margin-right : 0px;
28 margin-top : 0;
29 padding-bottom : 10px;
30 padding-left : 10px;
31 padding-right : 10px;
32 padding-top : 10px;
33 width : 90%;
36 H1, H2, H3, P {
37 background-color : inherit;
38 margin : 0 0 15px;
39 padding-bottom : 0;
40 padding-left : 0;
41 padding-right : 0;
42 padding-top : 0;
45 H1, H2 {
46 color : #bbb;
49 H1 {
50 font-size : 20px;
51 font-weight : 900;
52 line-height : 28px;
55 H2 {
56 font-size : 18px;
57 font-weight : 700;
58 line-height : 20px;
61 H3 {
62 color : #333;
63 font-size : 18px;
64 line-height : 18px;
67 P {
68 clear : both; /* needed for Opera 6.12 */
69 color : #333;
70 float : none;
71 font-size : 11px;
72 line-height : 20px;
75 DIV.Legend {
76 background-color : #eee;
77 color : inherit;
78 clear : both;
79 float : none;
80 font-size : 10px;
81 margin-bottom : 10px;
82 position : relative;
83 width : 90%;
86 DIV.LegendRow {
87 clear : both;
88 float : none;
89 margin-bottom: 2px;
92 DIV.LegendRow SPAN.LegendName {
93 font-weight : bold;
94 text-align : left;
95 padding-right : 5px;
98 DIV.LegendRow SPAN.LegendValue {
99 text-align : left;
102 P.Variables SPAN.VariableName {
103 font-weight : bold;
106 DIV.Graph, DIV.ShortGraph {
107 clear : left;
108 float : left;
109 margin-bottom : 10px;
110 margin-top : 15px;
111 position : relative;
112 width : 100%;
115 </STYLE>
116 </HEAD>
117 <BODY>
119 <DIV CLASS="Content">
121 [% graphdescr=nodeParam(token,'descriptive-nickname');
122 IF graphdescr.length > 0 %]
123 <H1>Graphs for [% graphdescr %]</H1>
124 [% END %]
126 [% INCLUDE variables %]
127 [% INCLUDE legend %]
129 [% IF nodeParam(token, 'ds-type') != 'rrd-multigraph' %]
130 [% dayValues = rrprint(token, 'rrd-print-daily') %]
131 [% lastValue = rrprint(token, 'rrd-print-last') %]
133 <P>24-hour minimum: [% scale('%.1f', dayValues.0) %], &nbsp;
134 average: [% scale('%.1f', dayValues.1) %], &nbsp;
135 maximum: <STRONG>[% scale('%.1f', dayValues.2) %]</STRONG>. &nbsp;
136 Last: [% scale('%.1f', lastValue) %]
137 </P>
138 [% END %]
141 graphvars = [];
142 graphviews = nodeParam(token,'rrgraph-views').split(',');
143 dayView = graphviews.1;
144 weekView = graphviews.2;
145 monthView = graphviews.3;
146 yearView = graphviews.4;
147 IF nodeParam(token, 'rrd-hwpredict') == 'enabled' and
148 ( param(view, 'rrd-hwpredict') == 'disabled' or variables.NOHW );
149 graphvars = ['NOHW', 1];
150 END;
153 <DIV CLASS="Graph">
154 <H2>Last day graph</H2>
155 [% INCLUDE rrgraph view=dayView vars=graphvars %]
156 </DIV>
158 <DIV CLASS="Graph">
159 <H2>Last week graph</H2>
160 [% INCLUDE rrgraph view=weekView vars=graphvars %]
161 </DIV>
163 <DIV CLASS="Graph">
164 <H2>Last month graph</H2>
165 [% INCLUDE rrgraph view=monthView %]
166 </DIV>
168 <DIV CLASS="Graph">
169 <H2>Last year graph</H2>
170 [% INCLUDE rrgraph view=yearView %]
171 </DIV>
173 </DIV><!-- Content -->
174 </BODY>
175 </HTML>