summaryrefslogtreecommitdiff
path: root/modules/popup-dialog.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2010-11-23 10:30:36 +0300
committerAndrew Dolgov <[email protected]>2010-11-23 10:30:36 +0300
commit63855db147e6efeaa6516dc2b95598b03d1b3ad5 (patch)
treea3475c2b6eb7dd71fe44fc7d358c414abcdac805 /modules/popup-dialog.php
parent6ef0c9c3426275612db693cad5d2c90df24ca714 (diff)
rework version checking
Diffstat (limited to 'modules/popup-dialog.php')
-rw-r--r--modules/popup-dialog.php33
1 files changed, 21 insertions, 12 deletions
diff --git a/modules/popup-dialog.php b/modules/popup-dialog.php
index 0a272d1a3..584f6e51d 100644
--- a/modules/popup-dialog.php
+++ b/modules/popup-dialog.php
@@ -217,17 +217,6 @@
}
- if ($param == 2) {
- $msg = check_for_update($link);
-
- if (!$msg) {
- print __("You are running the latest version of Tiny Tiny RSS. The fact that you are seeing this dialog is probably a bug.");
- } else {
- print $msg;
- }
-
- }
-
if ($param == 3) {
print __("Update daemon is taking too long to perform a feed update. This could indicate a problem like crash or a hang. Please check the daemon process or contact instance owner.");
@@ -241,7 +230,7 @@
print "<div align='center'>";
- print "<button onclick=\"return closeInfoBox()\"".
+ print "<button onclick=\"return closeInfoBox()\">".
__('Close this window')."</button>";
print "</div>";
@@ -777,6 +766,26 @@
//return;
}
+ if ($id == "newVersion") {
+ $version = check_for_update($link);
+
+ $version_link = "<a class=\"visibleLink\" target=\"_blank\"
+ href=\"http://tt-rss.org\">http://tt-rss.org</a>";
+
+ print "<div class='tagCloudContainer'>";
+
+ print T_sprintf("New version of Tiny Tiny RSS is available (%s).<br/>Visit %s for more information.", "<b>$version</b>", $version_link);
+
+ print "</div>";
+
+ print "<div style='text-align : center'>";
+ print "<button dojoType=\"dijit.form.Button\"
+ onclick=\"return dijit.byId('newVersionDlg').hide()\">".
+ __('Close this window')."</button>";
+ print "</div>";
+
+ }
+
print "</dlg>";
}
?>