Projet

Général

Profil

« Précédent | Suivant » 

Révision 6bd30fed

Ajouté par Colin Fleming il y a presque 10 ans

Tidy up "diag_smart.php" XHTML

Add PHP "closehead" variable
Add CDATA sections and TYPE to STYLE tag
Add SUMMARY to TABLES
Update HTML Boolean operators
Tidy up OPTION tags

Voir les différences:

usr/local/www/diag_smart.php
20 20
$valid_info_types = array("i", "H", "c", "A", "a");
21 21
$valid_log_types = array("error", "selftest");
22 22

  
23

  
23
$closehead = false;
24 24
include("head.inc");
25 25
?>
26 26

  
27
<style>
28
<!--
27
<style type="text/css">
28
/*<![CDATA[*/
29 29

  
30 30
input {
31 31
	font-family: courier new, courier;
......
55 55
	font-size: 11px;
56 56
}
57 57

  
58
-->
58
/*]]>*/
59 59
</style>
60 60
</head>
61 61
<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
......
207 207

  
208 208
		?>
209 209
		<!-- Print the tabs across the top -->
210
		<table width="100%" border="0" cellpadding="0" cellspacing="0">
210
		<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="tabs">
211 211
			<tr>
212 212
				<td>
213 213
					<?php
......
221 221
		</table>
222 222
<!-- user email address -->
223 223
		<form action="<?= $_SERVER['PHP_SELF']?>" method="post" name="config">
224
		<table width="100%" border="0" cellpadding="6" cellspacing="0">
224
		<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="e-mail">
225 225
			<tbody>
226 226
				<tr>
227 227
					<td colspan="2" valign="top" class="listtopic"><?=gettext("Config"); ?></td>
......
246 246

  
247 247
<!-- test email -->
248 248
		<form action="<?= $_SERVER['PHP_SELF']?>" method="post" name="config">
249
		<table width="100%" border="0" cellpadding="6" cellspacing="0">
249
		<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="test e-mail">
250 250
			<tbody>
251 251
				<tr>
252 252
					<td colspan="2" valign="top" class="listtopic"><?=gettext("Test email"); ?></td>
......
279 279
		// Get all AD* and DA* (IDE and SCSI) devices currently installed and stores them in the $devs array
280 280
		exec("ls /dev | grep '^\(ad\|da\|ada\)[0-9]\{1,2\}$'", $devs);
281 281
		?>
282
		<table width="100%" border="0" cellpadding="0" cellspacing="0">
282
		<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="default page">
283 283
			<tr>
284 284
				<td>
285 285
					<?php
......
293 293
		</table>
294 294
<!--INFO-->
295 295
		<form action="<?= $_SERVER['PHP_SELF']?>" method="post" name="info">
296
		<table width="100%" border="0" cellpadding="6" cellspacing="0">
296
		<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="info">
297 297
			<tbody>
298 298
				<tr>
299 299
					<td colspan="2" valign="top" class="listtopic"><?=gettext("Info"); ?></td>
......
302 302
					<td width="22%" valign="top" class="vncell"><?=gettext("Info type"); ?></td>
303 303
					<td width="78%" class="vtable">
304 304
						<input type="radio" name="type" value="i" /><?=gettext("Info"); ?><br />
305
						<input type="radio" name="type" value="H" checked /><?=gettext("Health"); ?><br />
305
						<input type="radio" name="type" value="H" checked="checked" /><?=gettext("Health"); ?><br />
306 306
						<input type="radio" name="type" value="c" /><?=gettext("SMART Capabilities"); ?><br />
307 307
						<input type="radio" name="type" value="A" /><?=gettext("Attributes"); ?><br />
308 308
						<input type="radio" name="type" value="a" /><?=gettext("All"); ?><br />
......
315 315
						<?php
316 316
						foreach($devs as $dev)
317 317
						{
318
							echo "<option value=" . $dev . ">" . $dev . "</option>";
318
							echo "<option value=\"" . $dev . "\">" . $dev . "</option>";
319 319
						}
320 320
						?>
321 321
						</select>
......
333 333
		</form>
334 334
<!--TESTS-->
335 335
		<form action="<?= $_SERVER['PHP_SELF']?>" method="post" name="tests">
336
		<table width="100%" border="0" cellpadding="6" cellspacing="0">
336
		<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="tests">
337 337
			<tbody>
338 338
				<tr>
339 339
					<td colspan="2" valign="top" class="listtopic"><?=gettext("Perform Self-tests"); ?></td>
......
342 342
					<td width="22%" valign="top" class="vncell"><?=gettext("Test type"); ?></td>
343 343
					<td width="78%" class="vtable">
344 344
						<input type="radio" name="testType" value="offline" /><?=gettext("Offline"); ?><br />
345
						<input type="radio" name="testType" value="short" checked /><?=gettext("Short"); ?><br />
345
						<input type="radio" name="testType" value="short" checked="checked" /><?=gettext("Short"); ?><br />
346 346
						<input type="radio" name="testType" value="long" /><?=gettext("Long"); ?><br />
347 347
						<input type="radio" name="testType" value="conveyance" /><?=gettext("Conveyance (ATA Disks Only)"); ?><br />
348 348
					</td>
......
354 354
						<?php
355 355
						foreach($devs as $dev)
356 356
						{
357
							echo "<option value=" . $dev . ">" . $dev;
357
							echo "<option value=\"" . $dev . "\">" . $dev . "</option>";
358 358
						}
359 359
						?>
360 360
						</select>
......
372 372
		</form>
373 373
<!--LOGS-->
374 374
		<form action="<?= $_SERVER['PHP_SELF']?>" method="post" name="logs">
375
		<table width="100%" border="0" cellpadding="6" cellspacing="0">
375
		<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="logs">
376 376
			<tbody>
377 377
				<tr>
378 378
					<td colspan="2" valign="top" class="listtopic"><?=gettext("View Logs"); ?></td>
......
380 380
				<tr>
381 381
					<td width="22%" valign="top" class="vncell"><?=gettext("Log type"); ?></td>
382 382
					<td width="78%" class="vtable">
383
						<input type="radio" name="type" value="error" checked /><?=gettext("Error"); ?><br />
383
						<input type="radio" name="type" value="error" checked="checked" /><?=gettext("Error"); ?><br />
384 384
						<input type="radio" name="type" value="selftest" /><?=gettext("Self-test"); ?><br />
385 385
					</td>
386 386
				</tr>
......
391 391
						<?php
392 392
						foreach($devs as $dev)
393 393
						{
394
							echo "<option value=" . $dev . ">" . $dev;
394
							echo "<option value=\"" . $dev . "\">" . $dev . "</option>";
395 395
						}
396 396
						?>
397 397
						</select>
......
409 409
		</form>
410 410
<!--ABORT-->
411 411
		<form action="<?= $_SERVER['PHP_SELF']?>" method="post" name="abort">
412
		<table width="100%" border="0" cellpadding="6" cellspacing="0">
412
		<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="abort">
413 413
			<tbody>
414 414
				<tr>
415 415
					<td colspan="2" valign="top" class="listtopic"><?=gettext("Abort tests"); ?></td>
......
421 421
						<?php
422 422
						foreach($devs as $dev)
423 423
						{
424
							echo "<option value=" . $dev . ">" . $dev;
424
							echo "<option value=\"" . $dev . "\">" . $dev . "</option>";
425 425
						}
426 426
						?>
427 427
						</select>

Formats disponibles : Unified diff