Projet

Général

Profil

« Précédent | Suivant » 

Révision fc82e8b6

Ajouté par Colin Fleming il y a presque 10 ans

Tidy up "diag_backup.php" XHTML

Add CDATA sections to SCRIPTS
Add SUMMARY to TABLES
Update HTML Boolean operators
Close INPUT tags
Add missing closing P tag

Voir les différences:

usr/local/www/diag_backup.php
203 203
		);
204 204

  
205 205
	$select  = "<select name=\"{$name}\" id=\"{$name}\">";
206
	$select .= "<option VALUE=\"\">" . gettext("ALL") . "</option>";
206
	$select .= "<option value=\"\">" . gettext("ALL") . "</option>";
207 207

  
208 208
	if($showall == true)
209 209
		foreach($areas as $area => $areaname)
210
			$select .= "<option value='{$area}'>{$areaname}</option>\n";
210
			$select .= "<option value=\"{$area}\">{$areaname}</option>\n";
211 211
	else
212 212
		foreach($areas as $area => $areaname)
213 213
			if($area === "rrddata" || check_and_returnif_section_exists($area) == true)
214
				$select .= "<option value='{$area}'>{$areaname}</option>\n";
214
				$select .= "<option value=\"{$area}\">{$areaname}</option>\n";
215 215

  
216 216
	$select .= "</select>\n";
217 217

  
218 218
	if ($name === "backuparea") {
219 219
		$select .= <<<END_SCRIPT_BLOCK
220
			<script type='text/javascript'>
220
			<script type="text/javascript">
221
			//<![CDATA[
221 222
				jQuery(function (\$) {
222 223
					$("#{$name}").change(function () {
223 224
						backuparea_change(this);
224 225
					}).trigger("change");
225 226
				});
227
			//]]>
226 228
			</script>
227 229
END_SCRIPT_BLOCK;
228 230
	}
......
587 589
<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
588 590
<?php include("fbegin.inc"); ?>
589 591
<script type="text/javascript">
590
<!--
592
//<![CDATA[
591 593

  
592 594
function encrypt_change() {
593 595

  
......
614 616
		document.getElementById("dotnotbackuprrd").disabled = false;
615 617
	}
616 618
}
617
//-->
619
//]]>
618 620
</script>
619 621

  
620 622
<?php if ($input_errors) print_input_errors($input_errors); ?>
621 623
<?php if ($savemsg) print_info_box($savemsg); ?>
622
<?php if (is_subsystem_dirty('restore')): ?><p>
624
<?php if (is_subsystem_dirty('restore')): ?><br/>
623 625
<form action="reboot.php" method="post">
624
<input name="Submit" type="hidden" value=" Yes ">
626
<input name="Submit" type="hidden" value="Yes" />
625 627
<?php print_info_box(gettext("The firewall configuration has been changed.") . "<br />" . gettext("The firewall is now rebooting."));?><br />
626 628
</form>
627 629
<?php endif; ?>
628 630
<form action="diag_backup.php" method="post" name="iform" enctype="multipart/form-data">
629
<table width="100%" border="0" cellspacing="0" cellpadding="0">
631
<table width="100%" border="0" cellspacing="0" cellpadding="0" summary="diag backup">
630 632
	<tr>
631 633
		<td>
632 634
<?php
......
640 642
	<tr>
641 643
		<td>
642 644
			<div id="mainarea">
643
			<table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0">
645
			<table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0" summary="main area">
644 646
				<tr>
645 647
					<td colspan="2" class="listtopic"><?=gettext("Backup configuration"); ?></td>
646 648
				</tr>
......
651 653
						<table>
652 654
							<tr>
653 655
								<td>
654
									<input name="nopackages" type="checkbox" class="formcheckbox" id="nopackages">
656
									<input name="nopackages" type="checkbox" class="formcheckbox" id="nopackages" />
655 657
								</td>
656 658
								<td>
657 659
									<span class="vexpl"><?=gettext("Do not backup package information."); ?></span>
......
661 663
						<table>
662 664
							<tr>
663 665
								<td>
664
									<input name="encrypt" type="checkbox" class="formcheckbox" id="nopackages" onClick="encrypt_change()">
666
									<input name="encrypt" type="checkbox" class="formcheckbox" id="nopackages" onclick="encrypt_change()" />
665 667
								</td>
666 668
								<td>
667 669
									<span class="vexpl"><?=gettext("Encrypt this configuration file."); ?></span>
......
669 671
							</tr>
670 672
							<tr>
671 673
								<td>
672
									<input name="donotbackuprrd" type="checkbox" class="formcheckbox" id="dotnotbackuprrd" checked>
674
									<input name="donotbackuprrd" type="checkbox" class="formcheckbox" id="dotnotbackuprrd" checked="checked" />
673 675
								</td>
674 676
								<td>
675 677
									<span class="vexpl"><?=gettext("Do not backup RRD data (NOTE: RRD Data can consume 4+ megabytes of config.xml space!)"); ?></span>
......
694 696
								</td>
695 697
							</tr>
696 698
						</table>
697
						<p><input name="Submit" type="submit" class="formbtn" id="download" value="<?=gettext("Download configuration"); ?>"></p>
699
						<p><input name="Submit" type="submit" class="formbtn" id="download" value="<?=gettext("Download configuration"); ?>" /></p>
698 700
					</td>
699 701
				</tr>
700 702
				<tr>
......
709 711
						<?=gettext("Open a"); ?> <?=$g['[product_name']?> <?=gettext("configuration XML file and click the button below to restore the configuration."); ?>
710 712
						<br /><br />
711 713
						<?=gettext("Restore area:"); ?> <?php spit_out_select_items("restorearea", true); ?>
712
						<p><input name="conffile" type="file" class="formbtn" id="conffile" size="40"></p>
714
						<p><input name="conffile" type="file" class="formbtn" id="conffile" size="40" /></p>
713 715
						<table>
714 716
							<tr>
715 717
								<td>
716
									<input name="decrypt" type="checkbox" class="formcheckbox" id="nopackages" onClick="decrypt_change()">
718
									<input name="decrypt" type="checkbox" class="formcheckbox" id="nopackages" onclick="decrypt_change()" />
717 719
								</td>
718 720
								<td>
719 721
									<span class="vexpl"><?=gettext("Configuration file is encrypted."); ?></span>
......
738 740
								</td>
739 741
							</tr>
740 742
						</table>
741
						<p><input name="Submit" type="submit" class="formbtn" id="restore" value="<?=gettext("Restore configuration"); ?>"></p>
743
						<p><input name="Submit" type="submit" class="formbtn" id="restore" value="<?=gettext("Restore configuration"); ?>" /></p>
742 744
						<p><strong><span class="red"><?=gettext("Note:"); ?></span></strong><br /><?=gettext("The firewall will reboot after restoring the configuration."); ?><br /></p>
743 745
					</td>
744 746
				</tr>
......
754 756
					<td width="78%" class="vtable">
755 757
						<?php if ($config['installedpackages']['package'] != "") { ?>
756 758
							<p><?=gettext("Click this button to reinstall all system packages.  This may take a while."); ?> <br /><br />
757
							<input name="Submit" type="submit" class="formbtn" id="reinstallpackages" value="<?=gettext("Reinstall packages"); ?>">
759
							<input name="Submit" type="submit" class="formbtn" id="reinstallpackages" value="<?=gettext("Reinstall packages"); ?>" />
758 760
							<br />
759 761
							<br />
760 762
						<?php } ?>
761 763
						<?php if (is_subsystem_dirty("packagelock")) { ?>
762 764
							<p><?=gettext("Click this button to clear the package lock if a package fails to reinstall properly after an upgrade."); ?> <br /><br />
763
							<input name="Submit" type="submit" class="formbtn" id="clearpackagelock" value="<?=gettext("Clear Package Lock"); ?>">
765
							<input name="Submit" type="submit" class="formbtn" id="clearpackagelock" value="<?=gettext("Clear Package Lock"); ?>" />
764 766
						<?php } ?>
767
							</p>
765 768
					</td>
766 769
				</tr>
767 770
				<?php } ?>
......
773 776
</form>
774 777

  
775 778
<script type="text/javascript">
776
<!--
779
//<![CDATA[
777 780
encrypt_change();
778 781
decrypt_change();
779
//-->
782
//]]>
780 783
</script>
781 784

  
782 785
<?php include("fend.inc"); ?>

Formats disponibles : Unified diff