Projet

Général

Profil

« Précédent | Suivant » 

Révision a3457472

Ajouté par Colin Fleming il y a presque 10 ans

Tidy up "diag_confbak.php" XHTML

Move VALIGN to STYLE statement
Add the colour WHITE other BGCOLOR will display error
Add SUMMARY to TABLES
Close INPUT and IMG tags
Move NOWRAP into CLASS statement
Remove duplicate closing FORM tag

Voir les différences:

usr/local/www/diag_confbak.php
118 118
			print_info_box($savemsg);
119 119
	?>
120 120
	<?php if ($diff) { ?>
121
	<table align="center" valign="middle" width="100%" border="0" cellspacing="0" style="padding-top: 4px; padding-bottom: 4px;">
121
	<table align="center" width="100%" border="0" cellspacing="0" style="padding-top: 4px; padding-bottom: 4px; vertical-align:middle;" summary="diag confbak">
122 122
		<tr><td><?=gettext("Configuration diff from");?> <?php echo date(gettext("n/j/y H:i:s"), $oldtime); ?> <?=gettext("to");?> <?php echo date(gettext("n/j/y H:i:s"), $newtime); ?></td></tr>
123 123
		<?php foreach ($diff as $line) {
124 124
			switch (substr($line, 0, 1)) {
......
132 132
					$color = "#a0a0a0";
133 133
					break;
134 134
				default:
135
					$color = "";
135
					$color = "#ffffff";
136 136
			}
137 137
			?>
138 138
		<tr>
......
142 142
	</table>
143 143
	<br />
144 144
	<?php } ?>
145
	<table width="100%" border="0" cellpadding="0" cellspacing="0">
145
	<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="stats">
146 146
		<tr>
147 147
			<td>
148 148
			<?php
......
157 157
			<td>
158 158
				<div id="mainarea">
159 159
					<form action="diag_confbak.php" method="post">
160
					<table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0">
160
					<table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0" summary="tabcont">
161 161
						<tr>
162 162
							<td width="10%">&nbsp;</td>
163 163
							<td width="15%" valign="top"><?=gettext("Backup Count");?></td>
164
							<td width="10%" align="top">
164
							<td width="10%">
165 165
							<input name="backupcount" type="text" class="formfld unknown" size="5" value="<?=htmlspecialchars($config['system']['backupcount']);?>"/>
166 166
							</td>
167 167
							<td width="60%">
168 168
							<?= gettext("Enter the number of older configurations to keep in the local backup cache. By default this is 30 for a full install or 5 on NanoBSD."); ?>
169 169
							</td>
170
							<td width= "5%"><input name="save" type="submit" class="formbtn" value="<?=gettext("Save"); ?>"></td>
170
							<td width= "5%"><input name="save" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" /></td>
171 171
						</tr>
172 172
						<tr>
173 173
							<td class="vncell">&nbsp;</td>
......
178 178
					</table>
179 179
					</form>
180 180
					<form action="diag_confbak.php" method="get">
181
					<table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0">
181
					<table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0" summary="difference">
182 182
						<?php if (is_array($confvers)): ?>
183 183
						<tr>
184 184
							<td colspan="7" class="list">
......
187 187
							</td>
188 188
						</tr>
189 189
						<tr>
190
							<td width="5%" colspan="2" valign="middle" align="center" class="list" nowrap><input type="submit" name="diff" value="<?=gettext("Diff"); ?>"></td>
190
							<td width="5%" colspan="2" valign="middle" align="center" class="list nowrap"><input type="submit" name="diff" value="<?=gettext("Diff"); ?>" /></td>
191 191
							<td width="20%" class="listhdrr"><?=gettext("Date");?></td>
192 192
							<td width="5%" class="listhdrr"><?=gettext("Version");?></td>
193 193
							<td width="5%" class="listhdrr"><?=gettext("Size");?></td>
......
195 195
							<td width="5%" class="list">&nbsp;</td>
196 196
						</tr>
197 197
						<tr valign="top">
198
							<td valign="middle" class="list" nowrap></td>
198
							<td valign="middle" class="list nowrap"></td>
199 199
							<td class="list">
200
								<input type="radio" name="newtime" value="current">
200
								<input type="radio" name="newtime" value="current" />
201 201
							</td>
202 202
							<td class="listlr"> <?= date(gettext("n/j/y H:i:s"), $config['revision']['time']) ?></td>
203 203
							<td class="listr"> <?= $config['version'] ?></td>
204 204
							<td class="listr"> <?= format_bytes(filesize("/conf/config.xml")) ?></td>
205 205
							<td class="listr"> <?= $config['revision']['description'] ?></td>
206
							<td valign="middle" class="list" nowrap><b><?=gettext("Current");?></b></td>
206
							<td valign="middle" class="list nowrap"><b><?=gettext("Current");?></b></td>
207 207
						</tr>
208 208
						<?php
209 209
							$c = 0;
......
215 215
						?>
216 216
						<tr valign="top">
217 217
							<td class="list">
218
								<input type="radio" name="oldtime" value="<?php echo $version['time'];?>">
218
								<input type="radio" name="oldtime" value="<?php echo $version['time'];?>" />
219 219
							</td>
220 220
							<td class="list">
221 221
								<?php if ($c < (count($confvers) - 1)) { ?>
222
								<input type="radio" name="newtime" value="<?php echo $version['time'];?>">
222
								<input type="radio" name="newtime" value="<?php echo $version['time'];?>" />
223 223
								<?php } else { ?>
224 224
								&nbsp;
225 225
								<?php }
......
229 229
							<td class="listr"> <?= $version['version'] ?></td>
230 230
							<td class="listr"> <?= format_bytes($version['filesize']) ?></td>
231 231
							<td class="listr"> <?= $version['description'] ?></td>
232
							<td valign="middle" class="list" nowrap>
233
							<a href="diag_confbak.php?newver=<?=$version['time'];?>" onclick="return confirm('<?=gettext("Revert to this configuration?");?>'")>
234
							<img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="<?=gettext("Revert to this configuration");?>" title="<?=gettext("Revert to this configuration");?>">
232
							<td valign="middle" class="list nowrap">
233
							<a href="diag_confbak.php?newver=<?=$version['time'];?>" onclick="return confirm('<?=gettext("Revert to this configuration?");?>')">
234
							<img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="<?=gettext("Revert to this configuration");?>" title="<?=gettext("Revert to this configuration");?>" />
235 235
								</a>
236 236
							<a href="diag_confbak.php?rmver=<?=$version['time'];?>" onclick="return confirm('<?=gettext("Delete this configuration backup?");?>')">
237
							<img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="<?=gettext("Remove this backup");?>" title="<?=gettext("Remove this backup");?>">
237
							<img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="<?=gettext("Remove this backup");?>" title="<?=gettext("Remove this backup");?>" />
238 238
								</a>
239 239
								<a href="diag_confbak.php?getcfg=<?=$version['time'];?>">
240
								<img src="/themes/<?= $g['theme']; ?>/images/icons/icon_down.gif" width="17" height="17" border="0" alt="<?=gettext("Download this backup");?>" title="<?=gettext("Download this backup");?>">
240
								<img src="/themes/<?= $g['theme']; ?>/images/icons/icon_down.gif" width="17" height="17" border="0" alt="<?=gettext("Download this backup");?>" title="<?=gettext("Download this backup");?>" />
241 241
								</a>
242 242
							</td>
243 243
						</tr>
244 244
						<?php endforeach; ?>
245 245
						<tr>
246
							<td colspan="2"><input type="submit" name="diff" value="<?=gettext("Diff"); ?>"></td>
246
							<td colspan="2"><input type="submit" name="diff" value="<?=gettext("Diff"); ?>" /></td>
247 247
							<td colspan="5"></td>
248 248
						</tr>
249 249
						<?php else: ?>
......
259 259
			</td>
260 260
		</tr>
261 261
	</table>
262
</form>
262

  
263 263
<?php include("fend.inc"); ?>
264 264
</body>
265 265
</html>

Formats disponibles : Unified diff