Subversion Repositories ALCASAR

Rev

Rev 324 | Rev 1846 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log

Rev Author Line No. Line
324 richard 1
<form action="stats.php" method="get">
2
<table border=0 width=600 cellpadding=2 cellspacing=0>
3
<tr>
4
	<td align=left>
5
	<table border=0 cellspacing=0 cellpadding=2>
6
	<tr valign=bottom>
7
		<td><small><b>De </td>
8
		<td><small><b>&agrave; </td>
9
		<td><small><b>usager</td>
10
		<td><small><b>sur le serveur</td>
11
		<td>&nbsp;</td>
12
		</tr>
13
	<tr valign=middle>
14
<?php
1831 raphael.pi 15
if(!isset($login))
16
{
17
	$login = "";
18
}
324 richard 19
echo <<<EOM
20
		<td valign=middle><input type="text" name="after"  size="12" value="$after" ></td>
21
		<td valign=middle><input type="text" name="before" size="12" value="$before"></td>
22
		<td valign=middle><input type="text" name="login"  size="12" value="$login" ></td>
23
		<td valign=middle><select name="server" size=1>
24
EOM;
25
foreach($servers as $key => $val)
26
	echo <<<EOM
27
	<option value="$val">$key
28
EOM;
29
?>
30
		</select></td>
31
		<td valign=middle><input type="submit" class=button value="Go"></td>
32
		</tr>
33
	</table>
34
	</td>
35
</tr>
36
<tr>
37
<td><hr size=1 noshade></td>
38
</tr>
39
<tr>
40
	<td valign=top>
41
	<table border=0 width="100%">
42
	<tr>	<td align=center valign=top width="45%">
43
		<small>
44
		<font color="darkblue"><b><?php echo $date ?></b></font>
45
		</td>
46
		<td align=center valign=top width="10%">&nbsp;</td>
47
		<td align=center valign=top width="45%"><small>
48
		P&eacute;riode observ&eacute;e :<br>
49
<?php
50
echo <<<EOM
51
		<b>$after</b>  &agrave;  <b>$before</b>
52
EOM;
53
?>
54
		</td>
55
		</tr>
56
	</table>
57
	</td>
58
</tr>
59
<tr>
60
	<td align=center><h1><b>Statistiques d'utilisation journali&egrave;re</td>
61
</tr>
62
<tr>
63
	<td valign=top>
64
	<table border=0 width="100%">
65
	<tr>
66
		<td colspan=2>
67
		<center>
68
		Statistiques pour 
69
<?php
70
if ($login == '')
71
	echo <<<EOM
72
<b><font color="darkblue">tous</font></b> les usagers
73
EOM;
74
else
75
	echo <<<EOM
76
l'usager <b><font color="darkblue">$login</font></b>
77
EOM;
78
?>
79
	</td>
80
	</tr>
81
	</table>
82
	</td>
83
</tr>
84
 
85
<tr>
86
	<td>
87
	<table border=0 cellpadding=0 cellspacing=0 width="100%">
88
	<tr>	<td colspan=2><hr size=1 noshade>
89
		</td>
90
		</tr>
91
 
92
	</table>
93
	</td>
94
	</tr>
95
<tr>
96
	<td align="center">
97
	<table border=0 cellpadding=0 cellspacing=1 width="100%">
1831 raphael.pi 98
 
99
 
100
 
324 richard 101
	<tr>
102
		<td>Champs affich&eacute;s :</td><td colspan=10 align=center nowrap><select name="column1">
1831 raphael.pi 103
		<option <?php if(isset($selected1[sessions])){print($selected1[session]);} ?> value="sessions">Nbre de sessions
104
		<option <?php if(isset($selected1[usage])){print($selected1[usage]);} ?> value="usage">Temps d'utilisation total
324 richard 105
		<option value="upload">------------------
1831 raphael.pi 106
		<option <?php if(isset($selected1[upload])){print($selected1[upload]);} ?> value="upload">uploads
107
		<option <?php if(isset($selected1[download])){print($selected1[download]);} ?> value="download">downloads
324 richard 108
	</select> <select name="column2">
1831 raphael.pi 109
		<option <?php if(isset($selected2[sessions])){print($selected2[session]);} ?> value="sessions">Nbre de sessions
110
		<option <?php if(isset($selected2[usage])){print($selected2[usage]);} ?> value="usage">Temps d'utilisation total
324 richard 111
		<option	value="upload">------------------
1831 raphael.pi 112
		<option <?php if(isset($selected2[upload])){print($selected2[upload]);} ?> value="upload">uploads
113
		<option <?php if(isset($selected2[download])){print($selected2[download]);} ?> value="download">downloads
324 richard 114
	</select> <select name="column3">
1831 raphael.pi 115
		<option <?php if(isset($selected3[sessions])){print($selected3[session]);} ?> value="sessions">Nbre de sessions
116
		<option <?php if(isset($selected3[usage])){print($selected3[usage]);} ?> value="usage">Temps d'utilisation total
324 richard 117
		<option value="upload">------------------
1831 raphael.pi 118
		<option <?php if(isset($selected3[upload])){print($selected3[upload]);} ?> value="upload">uploads
119
		<option <?php if(isset($selected3[download])){print($selected3[download]);} ?> value="download">downloads
120
 
121
 
324 richard 122
		</select>
123
		</td>
124
	</tr>
125
	<tr>
126
		<td colspan=10 align=center valign=middle>
127
		<table border=0 width="100%">
128
		<tr>
129
			<td width=50% align=left>
130
			<table border=0 cellpadding=0 cellspacing=0>
131
			<tr>
132
			<td align=right><input type="submit" class=button value="Rafra&icirc;chir"></td>
133
			</tr>
134
			</table>
135
			</td>
136
		</tr>
137
		</table>
138
		</td>
139
	</tr>
140
	</table>
141
	</td>
142
	<tr>
143
	<td colspan=10 height=20><img src="images/pixel.gif"></td>
144
	</tr>
145
	<tr>
146
		<td colspan=10 height=20 align=center>
147
		<table border=0 width=640 cellpadding=1 cellspacing=1>
148
		<tr valign=top>
149
				<td width=440></td>
150
				<td bgcolor="black" width=200>
151
					<table border=0 width=100% cellpadding=2 cellspacing=0>
152
					<tr bgcolor="#907030" align=right valign=top><th>
153
							<font color="white">Analyse journali&egrave;re</font>&nbsp;
154
					</th></tr>
155
					</table>
156
				</td></tr>
157
		<tr valign=top><td colspan=2>
158
			<table border=0 width=100% cellpadding=12 cellspacing=0 bgcolor="#ffffd0" valign=top>
159
			<tr><td>
160
				<p>
161
				<table border=1 bordercolordark=#ffffe0 bordercolorlight=#000000 width=100% cellpadding=2 cellspacing=0 bgcolor="#ffffe0" valign=top>
162
				<tr bgcolor="#d0ddb0">
163
					<th>date</th>
164
<?php
165
echo <<<EOM
166
	<th colspan=3>$message[$column1]</th>
167
	<th colspan=3>$message[$column2]</th>
168
	<th colspan=3>$message[$column3]</th>
169
EOM;
170
?>
171
				</tr>
172
<?php
173
	for($i = 0; $i <= $num_days; $i++){
174
		$day = $days[$i];
175
		$trcolor = ($i % 2) ? "#f7f7e4" : "#efefe4";
176
		echo <<<EOM
177
	<tr align=center bgcolor="$trcolor">
178
		<td>$day</td>
179
		<td>{$data[$day][1]}</td>
180
		<td>{$perc[$day][1]}</td>
181
		<td align=left height=14>
182
			<table border=0 cellpadding=0>
183
			<tr>
184
				<td bgcolor="{$color[$day][1]}" width={$width[$day][1]}><img border=0 height=14 width={$width[$day][1]} src="images/pixel.gif" alt="the $message[$column1] for $day is {$data[$day][1]}"></td>
185
			</tr>
186
			</table>
187
		</td>
188
		<td>{$data[$day][2]}</td>
189
		<td>{$perc[$day][2]}</td>
190
		<td align=left height=14>
191
			<table border=0 cellpadding=0>
192
			<tr>
193
				<td bgcolor="{$color[$day][2]}" width={$width[$day][2]}><img border=0 height=14 width={$width[$day][2]} src="images/pixel.gif" alt="the $message[$column3] for $day is {$data[$day][2]}"></td>
194
			</tr>
195
			</table>
196
		</td>
197
		<td>{$data[$day][3]}</td>
198
		<td>{$perc[$day][3]}</td>
199
		<td align=left height=14>
200
			<table border=0 cellpadding=0>
201
			<tr>
202
			<td bgcolor="{$color[$day][3]}" width={$width[$day][3]}><img border=0 height=14 width={$width[$day][3]} src="images/pixel.gif" alt="the $message[$column3] for $day is {$data[$day][3]}"></td>
203
			</tr>
204
			</table>
205
		</td>
206
		</tr>
207
EOM;
208
}
209
?>
210
</table>
211
</td></tr>
212
</table>
213
</td></tr>
214
</table>
215
</td></tr>
216
</table>
217
<p>
218
<table border=0 width=640 cellpadding=1 cellspacing=1>
219
<tr valign=top>
220
<td width=440></td>
221
<td bgcolor="black" width=200>
222
	<table border=0 width=100% cellpadding=2 cellspacing=0>
223
	<tr bgcolor="#907030" align=right valign=top><th>
224
	<font color="white">R&eacute;capitulatif journalier</font>&nbsp;
225
	</th></tr>
226
	</table>
227
</td></tr>
228
<tr bgcolor="black" valign=top><td colspan=2>
229
	<table border=0 width=100% cellpadding=12 cellspacing=0 bgcolor="#ffffd0" valign=top>
230
	<tr><td>
231
<p>
232
	<table border=1 bordercolordark=#ffffe0 bordercolorlight=#000000 width=100% cellpadding=2 cellspacing=0 bgcolor="#ff
233
ffe0" valign=top>
234
	<tr bgcolor="#d0ddb0">
235
	<th>&nbsp;</th>
236
<?php
237
echo <<<EOM
238
	<th>$message[$column1]</th>
239
	<th>$message[$column2]</th>
240
	<th>$message[$column3]</th>
241
EOM;
242
?>
243
	</tr>
244
<?php
245
echo <<<EOM
246
		<tr align=center bgcolor="#efefe4">
247
			<td>maximum</td>
1831 raphael.pi 248
			<td>{$data['max'][1]}</td>
249
			<td>{$data['max'][2]}</td>
250
			<td>{$data['max'][3]}</td>
324 richard 251
			</tr>
252
		<tr align=center bgcolor="#f7f7e4">
253
			<td>moyenne</td>
1831 raphael.pi 254
			<td>{$data['avg'][1]}</td>
255
			<td>{$data['avg'][2]}</td>
256
			<td>{$data['avg'][3]}</td>
324 richard 257
			</tr>
258
		<tr align=center bgcolor="#efefe4">
259
			<td>r&eacute;capitulatif</td>
1831 raphael.pi 260
			<td>{$data['sum'][1]}</td>
261
			<td>{$data['sum'][2]}</td>
262
			<td>{$data['sum'][3]}</td>
324 richard 263
			</tr>
264
EOM;
265
?>
266
</table>
267
		</table>
268
		</td></tr>
269
	</table>
270
	</td></tr>
271
</table>
272
</form>
273
</center>
274
</body>
275
</html>