summaryrefslogtreecommitdiffstats
path: root/usr/local/www
diff options
context:
space:
mode:
authorColin Fleming <cj_fleming@sky.com>2013-02-06 19:27:32 +0000
committerColin Fleming <cj_fleming@sky.com>2013-02-06 19:27:32 +0000
commit52593da5dbff0bfa2dc86f1e8c28c9a5632ea4d6 (patch)
tree35dc6a187010dbbdc3d33c71dbf2946aa1aa2338 /usr/local/www
parent0715ad5093226a9fd29b1abbbf57a9892efe4100 (diff)
downloadpfsense-52593da5dbff0bfa2dc86f1e8c28c9a5632ea4d6.zip
pfsense-52593da5dbff0bfa2dc86f1e8c28c9a5632ea4d6.tar.gz
Update HTML in "include" files
Udated the DOCTYPE to make it W3C standard/compliant. Moved "sorttable.js", "ticker.js" and the "antiClickJack style" from "fbegin.inc" and place them in "head.inc" (where they belong), this may also help the Widescreen package to work. Close BR, INPUT and IMG tags properly, update IMG tags with "alt" and update TABLE tags with "summary". Updated the SCRIPT and STYLE with proper CDATA sections. Updated LINK with the correct types.
Diffstat (limited to 'usr/local/www')
-rwxr-xr-xusr/local/www/fbegin.inc36
-rwxr-xr-xusr/local/www/fend.inc2
-rwxr-xr-xusr/local/www/head.inc40
-rw-r--r--usr/local/www/headjs.php10
4 files changed, 51 insertions, 37 deletions
diff --git a/usr/local/www/fbegin.inc b/usr/local/www/fbegin.inc
index 9a1b12a..1db4fea 100755
--- a/usr/local/www/fbegin.inc
+++ b/usr/local/www/fbegin.inc
@@ -1,11 +1,3 @@
-
-<script src="/javascript/sorttable.js"></script>
-<script src="/javascript/ticker.js"></script>
-<style id="antiClickjack">body{display:none}</style> <script type="text/JavaScript">
-if (self === top) { var antiClickjack = document.getElementById("antiClickjack"); antiClickjack.parentNode.removeChild(antiClickjack);
-} else { top.location = self.location;
-}
-</script>
<?php
/*
pfSense_MODULE: header
@@ -156,13 +148,13 @@ $services_menu[] = array(gettext("IGMP proxy"), "/services_igmpproxy.php");
$services_menu[] = array(gettext("Load Balancer"), "/load_balancer_pool.php");
$services_menu[] = array(gettext("NTP"), "/services_ntpd.php");
$services_menu[] = array(gettext("PPPoE Server"), "/vpn_pppoe.php");
-$services_menu[] = array(gettext("RIP"), "/pkg_edit.php?xml=routed.xml&id=0");
+$services_menu[] = array(gettext("RIP"), "/pkg_edit.php?xml=routed.xml&amp;id=0");
$services_menu[] = array(gettext("SNMP"), "/services_snmp.php");
if(count($config['interfaces']) > 1) {
/* no use for UPnP in single-interface deployments
remove to reduce user confusion
*/
- $services_menu[] = array(gettext("UPnP &amp; NAT-PMP"), "/pkg_edit.php?xml=miniupnpd.xml&id=0");
+ $services_menu[] = array(gettext("UPnP &amp; NAT-PMP"), "/pkg_edit.php?xml=miniupnpd.xml&amp;id=0");
}
$services_menu[] = array(gettext("Wake on LAN"), "/services_wol.php");
$services_menu = msort(array_merge($services_menu, return_ext_menu("Services")),0);
@@ -264,12 +256,12 @@ if(! $g['disablehelpmenu']) {
<div id="wrapper">
<div id="header">
- <div id="header-left"><a href="/index.php" id="status-link"><img src="/themes/<?= $g['theme']; ?>/images/transparent.gif" border="0"></a></div>
+ <div id="header-left"><a href="/index.php" id="status-link"><img src="/themes/<?= $g['theme']; ?>/images/transparent.gif" border="0" alt="transparent" /></a></div>
<div id="header-right">
<div class="container">
<div class="left">webConfigurator</div>
<div class="right" id="menu_messages">
-<?
+<?php
echo get_menu_messages();
?>
</div>
@@ -307,7 +299,7 @@ if(! $g['disablehelpmenu']) {
<li class="drop">
<div><?php echo gettext("Services"); ?></div>
<ul class="subdrop">
- <?
+ <?php
output_menu($services_menu);
?>
</ul>
@@ -331,7 +323,7 @@ if(! $g['disablehelpmenu']) {
<li class="drop">
<div><?php echo gettext("Diagnostics"); ?></div>
<ul id="diag" class="subdrop">
- <?
+ <?php
output_menu($diagnostics_menu);
?>
</ul>
@@ -340,8 +332,8 @@ if(! $g['disablehelpmenu']) {
<li class="lastdrop">
<div><?php echo gettext("Help"); ?></div>
<ul id="help" class="subdrop">
- <?
- output_menu($help_menu, "_new");
+ <?php
+ output_menu($help_menu, "_blank");
?>
</ul>
</li>
@@ -365,16 +357,16 @@ echo "\t<script type=\"text/javascript\" src=\"javascript/domTT/fadomatic.js\"><
$notices = get_notices();
if(!$notices) {
$need_alert_display = true;
- $display_text = print_notices($notices) . "<br>";
+ $display_text = print_notices($notices) . "<br />";
}
}
if($need_alert_display == true) {
echo "<div style=\"background-color:#000000\" id=\"roundalert\">";
- echo "<table>";
+ echo "<table summary=\"round alert\">";
echo "<tr><td><font color=\"#ffffff\">";
- echo "&nbsp;&nbsp;<img align=\"middle\" src=\"/top_notification.gif\">&nbsp;&nbsp;&nbsp;";
+ echo "&nbsp;&nbsp;<img align=\"middle\" src=\"/top_notification.gif\" alt=\"notification\" />&nbsp;&nbsp;&nbsp;";
echo $display_text;
- echo "</td>";
+ echo "</font></td>";
echo "</tr>";
echo "</table>";
echo "</div>";
@@ -417,7 +409,7 @@ echo get_shortcut_log_link($shortcut_section, true);
?>
<?php if(! $g['disablehelpicon']): ?>
-<a href="<?php echo $helpurl; ?>" title="<?php echo gettext("Help for items on this page"); ?>"><img style="vertical-align:middle" src="/themes/<?php echo $g['theme']; ?>/images/icons/icon_help.gif" border="0"></a>
+<a href="<?php echo $helpurl; ?>" title="<?php echo gettext("Help for items on this page"); ?>"><img style="vertical-align:middle" src="/themes/<?php echo $g['theme']; ?>/images/icons/icon_help.gif" border="0" alt="help" /></a>
<?php endif; ?>
</span>
</div>
@@ -427,7 +419,7 @@ echo get_shortcut_log_link($shortcut_section, true);
/* if upgrade in progress, alert user */
if(is_subsystem_dirty('packagelock')) {
$pgtitle = array(gettext("System"),gettext("Package Manager"));
- print_info_box(gettext("Packages are currently being reinstalled in the background.<p>Do not make changes in the GUI until this is complete.") . "<p><img src='/themes/{$g['theme']}/images/icons/icon_fw-update.gif'>");
+ print_info_box(gettext("Packages are currently being reinstalled in the background.<p>Do not make changes in the GUI until this is complete.") . "<p><img src='/themes/{$g['theme']}/images/icons/icon_fw-update.gif' alt='firmware update' />");
}
$pgtitle_output = true;
?>
diff --git a/usr/local/www/fend.inc b/usr/local/www/fend.inc
index dde5955..6ee1028 100755
--- a/usr/local/www/fend.inc
+++ b/usr/local/www/fend.inc
@@ -18,8 +18,10 @@
/* Disable form autocomplete on all but the login screen. */
if (basename($_SERVER["SCRIPT_FILENAME"] != "index.php") && !$allowautocomplete): ?>
<script type="text/javascript">
+//<![CDATA[
(function ($) {
$("input").attr("autocomplete","off");
})(jQuery);
+//]]>
</script>
<?php endif; ?>
diff --git a/usr/local/www/head.inc b/usr/local/www/head.inc
index c8454a6..0bc1d00 100755
--- a/usr/local/www/head.inc
+++ b/usr/local/www/head.inc
@@ -9,37 +9,57 @@ $pagetitle = gentitle( $pgtitle );
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<title><?php echo($config['system']['hostname'] . "." . $config['system']['domain'] . " - " . $pagetitle); ?></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link rel="apple-touch-icon" href="/themes/<?php echo $g['theme']; ?>/apple-touch-icon.png"/>
<?php
if (file_exists("{$g['www_path']}/themes/{$g['theme']}/table.css")):
- echo "<link rel=\"stylesheet\" href=\"/themes/{$g['theme']}/table.css\" />";
+ echo "<link type=\"text/css\" rel=\"stylesheet\" href=\"/themes/{$g['theme']}/table.css\" />";
else:
- echo "<link rel=\"stylesheet\" href=\"/css/table.css\" media=\"all\" />";
+ echo "<link type=\"text/css\" rel=\"stylesheet\" href=\"/css/table.css\" media=\"all\" />";
endif;
?>
-
+
<?php if (strpos($_SERVER["SCRIPT_FILENAME"], "wizard.php") !== false &&
file_exists("{$g['www_path']}/themes/{$g['theme']}/wizard.css")): ?>
- <?php echo "<style type=\"text/css\" src=\"/themes/{$g['theme']}/wizard.css\"></style>"; ?>
+ <?php echo "<link type=\"text/css\" rel=\"stylesheet\" href=\"/themes/{$g['theme']}/wizard.css\" />"; ?>
<?php else: ?>
- <link rel="stylesheet" href="/themes/<?php echo $g['theme']; ?>/all.css" media="all" />
+ <link type="text/css" rel="stylesheet" href="/themes/<?php echo $g['theme']; ?>/all.css" media="all" />
<?php endif; ?>
- <link rel="stylesheet" type="text/css" href="/niftycssCode.css">
- <link rel="stylesheet" type="text/css" href="/niftycssprintCode.css" media="print">
- <link rel="stylesheet" type="text/css" href="/themes/<?=$g['theme']?>/new_tab_menu.css" media="all">
+ <link rel="stylesheet" type="text/css" href="/niftycssCode.css" />
+ <link rel="stylesheet" type="text/css" href="/niftycssprintCode.css" media="print" />
+ <link rel="stylesheet" type="text/css" href="/themes/<?=$g['theme']?>/new_tab_menu.css" media="all" />
<script type="text/javascript" src="/javascript/niftyjsCode.js"></script>
<script type="text/javascript" src="/javascript/jquery.js"></script>
<script type="text/javascript" src="/javascript/jquery/jquery-ui.custom.min.js"></script>
<script type="text/javascript">
+ //<![CDATA[
var theme = "<?php echo $g['theme']; ?>";
jQuery.noConflict();
+ //]]>
</script>
+
+ <script type="text/javascript" src="/javascript/sorttable.js"></script>
+ <script type="text/javascript" src="/javascript/ticker.js"></script>
+ <style type="text/css" id="antiClickjack">
+ /*<![CDATA[*/
+ body{display:none}
+ /*]]>*/
+ </style>
+ <script type="text/javascript">
+ //<![CDATA[
+ if (self === top) {
+ var antiClickjack = document.getElementById("antiClickjack"); antiClickjack.parentNode.removeChild(antiClickjack);
+ } else {
+ top.location = self.location;
+ }
+ //]]>
+ </script>
+
<?php echo "\t<script type=\"text/javascript\" src=\"/themes/{$g['theme']}/loader.js\"></script>\n"; ?>
<?php
if($_GET['enablefirebuglite']) {
diff --git a/usr/local/www/headjs.php b/usr/local/www/headjs.php
index 197d806..bfea6e9 100644
--- a/usr/local/www/headjs.php
+++ b/usr/local/www/headjs.php
@@ -63,7 +63,7 @@ function getHeadJS() {
jQuery(\"#submit\").click(submit_form);
jQuery('#submit').click(function() {return false;});
- var to_insert = \"<div style='visibility:hidden' id='loading' name='loading'><img src='{$loader_gif}' \/><\/div>\";
+ var to_insert = \"<div style='visibility:hidden' id='loading' name='loading'><img src='{$loader_gif}' alt='loader' \/><\/div>\";
jQuery('#submit').before(to_insert);
}
}
@@ -73,7 +73,7 @@ function getHeadJS() {
//alert(Form.serialize($('iform')));
if(jQuery('#inputerrors'))
- jQuery('#inputerrors').html('<center><b><i>Loading...</i></b></center>');
+ jQuery('#inputerrors').html('<center><b><i>Loading...<\/i><\/b><\/center>');
/* dsh: Introduced because pkg_edit tries to set some hidden fields
* if executing submit's onclick event. The click gets deleted
@@ -134,10 +134,10 @@ function getHeadJS() {
return;
}
- message_html = '<table height=\"32\" width=\"100%\"><tr><td>';
+ message_html = '<table height=\"32\" width=\"100%\" summary=\"redbox\"><tr><td>';
message_html += '<div style=\"background-color:#990000\" id=\"redbox\">';
- message_html += '<table width=\"100%\"><tr><td width=\"8%\">';
- message_html += '<img style=\"vertical-align:center\" src=\"/themes/{$g['theme']}/images/icons/icon_exclam.gif\" width=\"28\" height=\"32\" \/>';
+ message_html += '<table width=\"100%\" summary=\"message\"><tr><td width=\"8%\">';
+ message_html += '<img style=\"vertical-align:center\" src=\"/themes/{$g['theme']}/images/icons/icon_exclam.gif\" width=\"28\" height=\"32\" alt=\"exclamation\" \/>';
message_html += '<\/td><td width=\"70%\"><font color=\"white\">';
message_html += '<b>' + message + '<\/b><\/font><\/td>';
OpenPOWER on IntegriCloud