diff options
author | Colin Fleming <cj_fleming@sky.com> | 2013-01-29 19:18:21 +0000 |
---|---|---|
committer | Colin Fleming <cj_fleming@sky.com> | 2013-01-29 19:18:21 +0000 |
commit | 28a0fc130e8ca236449282a44388a46f1eafe1f9 (patch) | |
tree | d5c31d18fab6845373dde08bbec6a4bb543971e0 | |
parent | 5d3183341f3289c5a7d70a1f584e5e6b5364736b (diff) | |
download | pfsense-packages-28a0fc130e8ca236449282a44388a46f1eafe1f9.tar.gz pfsense-packages-28a0fc130e8ca236449282a44388a46f1eafe1f9.tar.bz2 pfsense-packages-28a0fc130e8ca236449282a44388a46f1eafe1f9.zip |
Update CRON package
Update CRON package to be more consistent with pfSense "Look-N-Feel",
added tabs for both "settings" and "edit" and tidied up the HTML code.
-rw-r--r-- | config/cron/cron.tmp | 44 | ||||
-rw-r--r-- | config/cron/cron_edit.tmp | 61 |
2 files changed, 55 insertions, 50 deletions
diff --git a/config/cron/cron.tmp b/config/cron/cron.tmp index 1834ba62..b9666e01 100644 --- a/config/cron/cron.tmp +++ b/config/cron/cron.tmp @@ -44,29 +44,29 @@ if ($_GET['act'] == "del") { } } +$pgtitle = array(gettext("Cron"),gettext("Settings")); include("head.inc"); ?> - <body link="#0000CC" vlink="#0000CC" alink="#0000CC"> <?php include("fbegin.inc"); ?> -<p class="pgtitle">Cron: Settings</p> <div id="mainlevel"> -<table width="100%" border="0" cellpadding="0" cellspacing="0"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="tabs"> <tr><td class="tabnavtbl"> <?php $tab_array = array(); $tab_array[] = array(gettext("Settings"), true, "/packages/cron/cron.php"); + $tab_array[] = array(gettext("Edit"), false, "/packages/cron/cron_edit.php"); display_top_tabs($tab_array); ?> </td></tr> </table> -<table width="100%" border="0" cellpadding="0" cellspacing="0"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="content"> <tr> <td class="tabcont" > @@ -85,7 +85,7 @@ if ($config_change == 1) { //endif; ?> - <table width="100%" border="0" cellpadding="6" cellspacing="0"> + <table width="100%" border="0" cellpadding="6" cellspacing="0" summary="title"> <tr> <td><p><!--<span class="vexpl"><span class="red"><strong>Cron<br></strong></span>--> Cron controls the scheduling of commands. @@ -96,7 +96,7 @@ if ($config_change == 1) { </table> <br /> - <table width="100%" border="0" cellpadding="0" cellspacing="0"> + <table width="100%" border="0" cellpadding="0" cellspacing="0" summary="heading"> <tr> <td width="5%" class="listhdrr">minute</td> <td width="5%" class="listhdrr">hour</td> @@ -107,10 +107,10 @@ if ($config_change == 1) { <td width="60%" class="listhdr">command</td> <td width="10%" class="list"> - <table border="0" cellspacing="0" cellpadding="1"> + <table border="0" cellspacing="0" cellpadding="1" summary="icons"> <tr> <td width="17"></td> - <td valign="middle"><a href="cron_edit.php"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td> + <td valign="middle"><a href="cron_edit.php"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="edit" /></a></td> </tr> </table> @@ -149,11 +149,11 @@ if ($config_change == 1) { <td class="listr" ondblclick="document.location='cron_edit.php?id=<?=$i;?>';"> <?=$ent['command'];?> </td> - <td valign="middle" nowrap class="list"> - <table border="0" cellspacing="0" cellpadding="1"> + <td valign="middle" style="white-space:nowrap" class="list"> + <table border="0" cellspacing="0" cellpadding="1" summary="edit delete"> <tr> - <td valign="middle"><a href="cron_edit.php?id=<?=$i;?>"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a></td> - <td><a href="cron_edit.php?type=php&act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this?')"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td> + <td valign="middle"><a href="cron_edit.php?id=<?=$i;?>"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0" alt="edit" /></a></td> + <td><a href="cron_edit.php?type=php&act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this?')"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="delete" /></a></td> </tr> </table> </td> @@ -168,10 +168,10 @@ if ($config_change == 1) { <tr> <td class="list" colspan="7"></td> <td class="list"> - <table border="0" cellspacing="0" cellpadding="1"> + <table border="0" cellspacing="0" cellpadding="1" summary="add"> <tr> <td width="17"></td> - <td valign="middle"><a href="cron_edit.php"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td> + <td valign="middle"><a href="cron_edit.php"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="add" /></a></td> </tr> </table> </td> @@ -187,14 +187,14 @@ if ($config_change == 1) { </form> -<br> -<br> -<br> -<br> -<br> -<br> -<br> -<br> +<br /> +<br /> +<br /> +<br /> +<br /> +<br /> +<br /> +<br /> </td> </tr> diff --git a/config/cron/cron_edit.tmp b/config/cron/cron_edit.tmp index 71367d24..67148af0 100644 --- a/config/cron/cron_edit.tmp +++ b/config/cron/cron_edit.tmp @@ -96,44 +96,48 @@ if ($_POST) { } } +$pgtitle = array(gettext("Cron"),gettext("Edit")); include("head.inc"); ?> -<script type="text/javascript" language="JavaScript"> +<body link="#0000CC" vlink="#0000CC" alink="#0000CC"> +<script type="text/javascript"> +//<![CDATA[ function show_advanced_config() { document.getElementById("showadvancedbox").innerHTML=''; aodiv = document.getElementById('showadvanced'); aodiv.style.display = "block"; +//]]> </script> -<body link="#0000CC" vlink="#0000CC" alink="#0000CC"> <?php include("fbegin.inc"); ?> -<p class="pgtitle">Cron: Edit</p> + <?php if ($input_errors) print_input_errors($input_errors); ?> <div id="mainlevel"> -<table width="100%" border="0" cellpadding="0" cellspacing="0"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="mainlevel"> <tr><td class="tabnavtbl"> <?php $tab_array = array(); $tab_array[] = array(gettext("Settings"), false, "/packages/cron/cron.php"); + $tab_array[] = array(gettext("Edit"), true, "/packages/cron/cron_edit.php"); display_top_tabs($tab_array); ?> </td></tr> </table> -<table width="100%" border="0" cellpadding="0" cellspacing="0"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="mainarea"> <tr> <td class="tabcont" > <!-- - <table width="100%" border="0" cellpadding="6" cellspacing="0"> + <table width="100%" border="0" cellpadding="6" cellspacing="0" summary="title"> <tr> - <td><p><span class="vexpl"><span class="red"><strong>Cron<br> + <td><p><span class="vexpl"><span class="red"><strong>Cron<br /> </strong></span> </p></td> </tr> @@ -142,7 +146,7 @@ function show_advanced_config() { <br /> <form action="cron_edit.php" method="post" name="iform" id="iform"> - <table width="100%" border="0" cellpadding="6" cellspacing="0"> + <table width="100%" border="0" cellpadding="6" cellspacing="0" summary="form"> @@ -150,49 +154,50 @@ function show_advanced_config() { <tr> <td width="25%" valign="top" class="vncellreq">minute</td> <td width="75%" class="vtable"> - <input name="minute" type="text" class="formfld" id="minute" size="40" value="<?=htmlspecialchars($pconfig['minute']);?>"> + <input name="minute" type="text" class="formfld" id="minute" size="40" value="<?=htmlspecialchars($pconfig['minute']);?>" /> </td> </tr> <tr> <td width="25%" valign="top" class="vncellreq">hour</td> <td width="75%" class="vtable"> - <input name="hour" type="text" class="formfld" id="hour" size="40" value="<?=htmlspecialchars($pconfig['hour']);?>"> + <input name="hour" type="text" class="formfld" id="hour" size="40" value="<?=htmlspecialchars($pconfig['hour']);?>" /> </td> </tr> <tr> <td width="25%" valign="top" class="vncellreq">mday</td> <td width="75%" class="vtable"> - <input name="mday" type="text" class="formfld" id="mday" size="40" value="<?=htmlspecialchars($pconfig['mday']);?>"> + <input name="mday" type="text" class="formfld" id="mday" size="40" value="<?=htmlspecialchars($pconfig['mday']);?>" /> </td> </tr> <tr> <td width="25%" valign="top" class="vncellreq">month</td> <td width="75%" class="vtable"> - <input name="month" type="text" class="formfld" id="month" size="40" value="<?=htmlspecialchars($pconfig['month']);?>"> + <input name="month" type="text" class="formfld" id="month" size="40" value="<?=htmlspecialchars($pconfig['month']);?>" /> </td> </tr> <tr> <td width="25%" valign="top" class="vncellreq">wday</td> <td width="75%" class="vtable"> - <input name="wday" type="text" class="formfld" id="wday" size="40" value="<?=htmlspecialchars($pconfig['wday']);?>"> + <input name="wday" type="text" class="formfld" id="wday" size="40" value="<?=htmlspecialchars($pconfig['wday']);?>" /> </td> </tr> <tr> <td width="25%" valign="top" class="vncellreq">who</td> <td width="75%" class="vtable"> - <input name="who" type="text" class="formfld" id="who" size="40" value="<?=htmlspecialchars($pconfig['who']);?>"> + <input name="who" type="text" class="formfld" id="who" size="40" value="<?=htmlspecialchars($pconfig['who']);?>" /> </td> </tr> <tr> <td width="25%" valign="top" class="vncellreq">command</td> <td width="75%" class="vtable"> - <input name="command" type="text" class="formfld" id="command" size="40" value="<?=htmlspecialchars($pconfig['command']);?>"> + <!-- <input name="command" type="text" class="formfld" id="command" size="40" value="<?=htmlspecialchars($pconfig['command']);?>" /> --> + <textarea rows="3" cols="68" name="command" id="command"><?=htmlspecialchars($pconfig['command']);?></textarea> </td> </tr> <!-- @@ -224,16 +229,16 @@ function show_advanced_config() { echo " <option></option>\n"; switch (htmlspecialchars($pconfig['enabled'])) { case "true": - echo " <option value='true' selected='yes'>true</option>\n"; + echo " <option value='true' selected='selected'>true</option>\n"; echo " <option value='false'>false</option>\n"; break; case "false": echo " <option value='true'>true</option>\n"; - echo " <option value='false' selected='yes'>false</option>\n"; + echo " <option value='false' selected='selected'>false</option>\n"; break; default: - echo " <option value='true' selected='yes'>true</option>\n"; + echo " <option value='true' selected='selected'>true</option>\n"; echo " <option value='false'>false</option>\n"; } echo " </select>\n"; @@ -245,8 +250,8 @@ function show_advanced_config() { <tr> <td width="25%" valign="top" class="vncellreq">Description</td> <td width="75%" class="vtable"> - <input name="description" type="text" class="formfld" id="description" size="40" value="<?=htmlspecialchars($pconfig['description']);?>"> - <br><span class="vexpl">Enter the description here.<br></span> + <input name="description" type="text" class="formfld" id="description" size="40" value="<?=htmlspecialchars($pconfig['description']);?>" /> + <br /><span class="vexpl">Enter the description here.<br /></span> </td> </tr> --> @@ -254,21 +259,21 @@ function show_advanced_config() { <tr> <td valign="top"> </td> <td> - <input name="Submit" type="submit" class="formbtn" value="Save"> <input class="formbtn" type="button" value="Cancel" onclick="history.back()"> + <input name="Submit" type="submit" class="formbtn" value="Save"> <input class="formbtn" type="button" value="Cancel" onclick="history.back()" /> <?php if (isset($id) && $a_cron[$id]): ?> - <input name="id" type="hidden" value="<?=$id;?>"> + <input name="id" type="hidden" value="<?=$id;?>" /> <?php endif; ?> </td> </tr> </table> </form> - <br> - <br> - <br> - <br> - <br> - <br> + <br /> + <br /> + <br /> + <br /> + <br /> + <br /> </td> </tr> |