]> git.wh0rd.org Git - tt-rss.git/commitdiff
fix some remaining old-style viewfeed() calls
authorAndrew Dolgov <noreply@fakecake.org>
Thu, 13 Aug 2015 06:51:39 +0000 (09:51 +0300)
committerAndrew Dolgov <noreply@fakecake.org>
Thu, 13 Aug 2015 06:51:39 +0000 (09:51 +0300)
classes/dlg.php
classes/feeds.php
include/functions2.php
js/functions.js
plugins/af_psql_trgm/init.php

index 7b1abca3a49ce1857a7248e2a95ab19afd84a96c..60c5265bf1dce14072e137ceb717180bf601c4d5 100644 (file)
@@ -144,7 +144,7 @@ class Dlg extends Handler_Protected {
 
                        $key_escaped = str_replace("'", "\\'", $key);
 
-                       echo "<a href=\"javascript:viewfeed('$key_escaped') \" style=\"font-size: " .
+                       echo "<a href=\"javascript:viewfeed({feed:'$key_escaped'}) \" style=\"font-size: " .
                                $size . "px\" title=\"$value articles tagged with " .
                                $key . '">' . $key . '</a> ';
                }
index 9e07057ba4f6e1a266e336ade83cbe8f5246c5ed..c3cb72da8db2a65fed524439f4e57ec6980e054d 100644 (file)
@@ -455,7 +455,7 @@ class Feeds extends Handler_Protected {
 
                                                        $reply['content'] .= "<div id='FTITLE-$feed_id' class='cdmFeedTitle'>".
                                                                "<div style='float : right'>$feed_icon_img</div>".
-                                                               "<a class='title' href=\"#\" onclick=\"viewfeed($feed_id)\">".
+                                                               "<a class='title' href=\"#\" onclick=\"viewfeed({feed:$feed_id})\">".
                                                                $line["feed_title"]."</a>
                                                                $vf_catchup_link</div>";
 
@@ -500,7 +500,7 @@ class Feeds extends Handler_Protected {
                                                if (@$line["feed_title"]) {
                                                        $rgba = @$rgba_cache[$feed_id];
 
-                                                       $reply['content'] .= "<span class=\"hlFeed\"><a style=\"background : rgba($rgba, 0.3)\" href=\"#\" onclick=\"viewfeed($feed_id)\">".
+                                                       $reply['content'] .= "<span class=\"hlFeed\"><a style=\"background : rgba($rgba, 0.3)\" href=\"#\" onclick=\"viewfeed({feed:$feed_id})\">".
                                                                truncate_string($line["feed_title"],30)."</a></span>";
                                                }
                                        }
@@ -517,7 +517,7 @@ class Feeds extends Handler_Protected {
 
                                        if ($line["feed_title"] && !$vfeed_group_enabled) {
 
-                                               $reply['content'] .= "<span onclick=\"viewfeed($feed_id)\"
+                                               $reply['content'] .= "<span onclick=\"viewfeed({feed:$feed_id})\"
                                                        style=\"cursor : pointer\"
                                                        title=\"".htmlspecialchars($line['feed_title'])."\">
                                                        $feed_icon_img</span>";
@@ -560,7 +560,7 @@ class Feeds extends Handler_Protected {
 
                                                        $reply['content'] .= "<div id='FTITLE-$feed_id' class='cdmFeedTitle'>".
                                                                "<div style=\"float : right\">$feed_icon_img</div>".
-                                                               "<a href=\"#\" class='title' onclick=\"viewfeed($feed_id)\">".
+                                                               "<a href=\"#\" class='title' onclick=\"viewfeed({feed:$feed_id})\">".
                                                                $line["feed_title"]."</a> $vf_catchup_link</div>";
 
                                                }
@@ -624,7 +624,7 @@ class Feeds extends Handler_Protected {
 
                                                        $reply['content'] .= "<div class=\"hlFeed\">
                                                                <a href=\"#\" style=\"background-color: rgba($rgba,0.3)\"
-                                                               onclick=\"viewfeed($feed_id)\">".
+                                                               onclick=\"viewfeed({feed:$feed_id})\">".
                                                                truncate_string($line["feed_title"],30)."</a>
                                                        </div>";
                                                }
@@ -639,7 +639,7 @@ class Feeds extends Handler_Protected {
                                        if (!get_pref("VFEED_GROUP_BY_FEED") && $line["feed_title"]) {
                                                $reply['content'] .= "<span style=\"cursor : pointer\"
                                                        title=\"".htmlspecialchars($line["feed_title"])."\"
-                                                       onclick=\"viewfeed($feed_id)\">$feed_icon_img</span>";
+                                                       onclick=\"viewfeed({feed:$feed_id})\">$feed_icon_img</span>";
                                        }
                                        $reply['content'] .= "</div>";
 
index 19012c8e27a7ee933105eb12bf12e27778f3957c..9bbfc7b2278dcef2db3c32f7cf8c07c80391c384 100644 (file)
                        $tags_str = "";
 
                        for ($i = 0; $i < $maxtags; $i++) {
-                               $tags_str .= "<a class=\"tag\" href=\"#\" onclick=\"viewfeed('".$tags[$i]."')\">" . $tags[$i] . "</a>, ";
+                               $tags_str .= "<a class=\"tag\" href=\"#\" onclick=\"viewfeed({feed:'".$tags[$i]."'})\">" . $tags[$i] . "</a>, ";
                        }
 
                        $tags_str = mb_substr($tags_str, 0, mb_strlen($tags_str)-2);
index 843edaec6700b7fabb1408d37801f1595055272a..8e5694960154d3aa8d6cdf506972d4b86df59f3d 100644 (file)
@@ -1240,7 +1240,7 @@ function unsubscribeFeed(feed_id, title) {
                                                updateFeedList();
                                        } else {
                                                if (feed_id == getActiveFeedId())
-                                                       setTimeout("viewfeed(-5)", 100);
+                                                       setTimeout("viewfeed({feed:-5})", 100);
 
                                                if (feed_id < 0) updateFeedList();
                                        }
index d83dff804e8d53683efc468c7b5ec6d4e0004ba6..d89c122f68a573aafac68331137843c65bda82cc 100644 (file)
@@ -88,7 +88,7 @@ class Af_Psql_Trgm extends Plugin {
                        print " <a target=\"_blank\" href=\"$article_link\">".
                                $line["title"]."</a>";
 
-                       print " (<a href=\"#\" onclick=\"viewfeed(".$line["feed_id"].")\">".
+                       print " (<a href=\"#\" onclick=\"viewfeed({feed:".$line["feed_id"]."})\">".
                                htmlspecialchars($line["feed_title"])."</a>)";
 
                        print " <span class='insensitive'>($sm)</span>";