summaryrefslogtreecommitdiffstats
path: root/usr
diff options
context:
space:
mode:
authorScott Dale <sdale@pfsense.org>2007-07-08 20:03:35 +0000
committerScott Dale <sdale@pfsense.org>2007-07-08 20:03:35 +0000
commitd955eecdc0454a39571ac747263d18ee71afaffd (patch)
treec69356aa05207cbadd3e848c285c841a58b3e8cb /usr
parent72209e47a4f7798ab6b958f4ee06bc3da95b084a (diff)
downloadpfsense-d955eecdc0454a39571ac747263d18ee71afaffd.zip
pfsense-d955eecdc0454a39571ac747263d18ee71afaffd.tar.gz
show available updates for packages
Diffstat (limited to 'usr')
-rw-r--r--usr/local/www/widgets/widgets/installed_packages.widget.php38
1 files changed, 28 insertions, 10 deletions
diff --git a/usr/local/www/widgets/widgets/installed_packages.widget.php b/usr/local/www/widgets/widgets/installed_packages.widget.php
index 8df13f4..5a52ab1 100644
--- a/usr/local/www/widgets/widgets/installed_packages.widget.php
+++ b/usr/local/www/widgets/widgets/installed_packages.widget.php
@@ -41,16 +41,18 @@ if(is_array($config['installedpackages']['package'])) {
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td width="15%" class="listhdrr">Package Name</td>
- <td width="20%" class="listhdrr">Category</td>
- <td width="10%" class="listhdrr">Package Version</td>
+ <td width="15%" class="listhdrr">Package Name</td>
+ <td width="15%" class="listhdrr">Category</td>
+ <td width="30%" class="listhdrr">Package Version</td>
</tr>
<?php
if($config['installedpackages']['package'] != "") {
$instpkgs = array();
foreach($config['installedpackages']['package'] as $instpkg) $instpkgs[] = $instpkg['name'];
asort($instpkgs);
+ $y=1;
foreach ($instpkgs as $index => $pkgname){
+
$pkg = $config['installedpackages']['package'][$index];
if($pkg['name'] <> "") {
?>
@@ -77,15 +79,19 @@ if(is_array($config['installedpackages']['package'])) {
}
elseif(strcmp($pkg['version'], $latest_package) < 0)
{
- /* our package is out of date */
- echo "Current: {$latest_package}";
- echo "<br>Installed: {$pkg['version']}";
-
+ /* our package is out of date */
+ ?>
+ <div id="updatediv-<?php echo $y; ?>" style="color:red">
+ <b>Update Available!</b></div><div style="float:left">
+ Current: <?php echo $latest_package; ?><br/>
+ Installed: <?php echo $pkg['version']; ?></div><div style="float:right">
+ <a href="pkg_mgr_install.php?mode=reinstallpkg&pkg=<?= $pkg['name']; ?>"><img title="Update this package." src="./themes/<?= $g['theme']; ?>/images/icons/icon_reinstall_pkg.gif" width="17" height="17" border="0"</a>
+ </div>
+ <?php $y++;
}
else
{
- echo $pkg['version'];
-
+ echo $pkg['version'];
}
?></td>
</tr>
@@ -96,4 +102,16 @@ if(is_array($config['installedpackages']['package'])) {
echo "<tr><td colspan=\"5\"><center>There are no packages currently installed.</td></tr>";
}
?>
- </table> \ No newline at end of file
+ </table>
+
+
+<script language="javascript" type="text/javascript">
+ window.onload = function(in_event)
+ {
+ for (y=1; y<=<?php echo $y;?>; y++){
+ textID = "updatediv-" + y;
+ Effect.Pulsate(textID,{from:0.1});
+ }
+ }
+</script>
+ \ No newline at end of file
OpenPOWER on IntegriCloud