|
|
@ -1329,30 +1329,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
print "</div>"; #pane
|
|
|
|
print "</div>"; #pane
|
|
|
|
|
|
|
|
|
|
|
|
print "<div id=\"pref-feeds-twitter\" dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Twitter')."\">";
|
|
|
|
if (defined('CONSUMER_KEY') && CONSUMER_KEY != '') {
|
|
|
|
|
|
|
|
|
|
|
|
$result = db_query($link, "SELECT COUNT(*) AS cid FROM ttrss_users
|
|
|
|
print "<div id=\"pref-feeds-twitter\" dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Twitter')."\">";
|
|
|
|
WHERE twitter_oauth IS NOT NULL AND twitter_oauth != '' AND
|
|
|
|
|
|
|
|
id = " . $_SESSION['uid']);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$is_registered = db_fetch_result($result, 0, "cid") != 0;
|
|
|
|
$result = db_query($link, "SELECT COUNT(*) AS cid FROM ttrss_users
|
|
|
|
|
|
|
|
WHERE twitter_oauth IS NOT NULL AND twitter_oauth != '' AND
|
|
|
|
|
|
|
|
id = " . $_SESSION['uid']);
|
|
|
|
|
|
|
|
|
|
|
|
if (!$is_registered) {
|
|
|
|
$is_registered = db_fetch_result($result, 0, "cid") != 0;
|
|
|
|
print_notice(__('Before you can update your Twitter feeds, you must register this instance of Tiny Tiny RSS with Twitter.com.'));
|
|
|
|
|
|
|
|
} else {
|
|
|
|
if (!$is_registered) {
|
|
|
|
print_notice(__('You have been successfully registered with Twitter.com and should be able to access your Twitter feeds.'));
|
|
|
|
print_notice(__('Before you can update your Twitter feeds, you must register this instance of Tiny Tiny RSS with Twitter.com.'));
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
|
|
|
|
print_notice(__('You have been successfully registered with Twitter.com and should be able to access your Twitter feeds.'));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
print "<button dojoType=\"dijit.form.Button\" onclick=\"window.location.href = 'twitter.php?op=register'\">".
|
|
|
|
|
|
|
|
__("Register with Twitter.com")."</button>";
|
|
|
|
|
|
|
|
|
|
|
|
print "<button dojoType=\"dijit.form.Button\" onclick=\"window.location.href = 'twitter.php?op=register'\">".
|
|
|
|
print " ";
|
|
|
|
__("Register with Twitter.com")."</button>";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
print " ";
|
|
|
|
print "<button dojoType=\"dijit.form.Button\"
|
|
|
|
|
|
|
|
onclick=\"return clearTwitterCredentials()\">".
|
|
|
|
|
|
|
|
__("Clear stored credentials")."</button>";
|
|
|
|
|
|
|
|
|
|
|
|
print "<button dojoType=\"dijit.form.Button\"
|
|
|
|
print "</div>"; # pane
|
|
|
|
onclick=\"return clearTwitterCredentials()\">".
|
|
|
|
|
|
|
|
__("Clear stored credentials")."</button>";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
print "</div>";
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
print "</div>"; #container
|
|
|
|
print "</div>"; #container
|
|
|
|
|
|
|
|
|
|
|
|