From: justauser Date: Sun, 7 Jul 2013 17:57:06 +0000 (-0400) Subject: Merge branch 'master' into hookhead X-Git-Tag: 1.9~61^2~1 X-Git-Url: https://git.wh0rd.org/?p=tt-rss.git;a=commitdiff_plain;h=3b96b0ed7cf8d960dd3ec2208ad8addb584bc1c9 Merge branch 'master' into hookhead Conflicts: include/functions.php changes for conflicts with master --- 3b96b0ed7cf8d960dd3ec2208ad8addb584bc1c9 diff --cc classes/handler/public.php index 810f4c03,b1546356..60a961bf --- a/classes/handler/public.php +++ b/classes/handler/public.php @@@ -85,18 -85,19 +85,21 @@@ class Handler_Public extends Handler } $tpl->setVariable('SELF_URL', htmlspecialchars(get_self_url_prefix()), true); - + $line["content_preview"] = truncate_string(strip_tags($line["content_preview"]), 100, '...'); while ($line = $this->dbh->fetch_assoc($result)) { + foreach (PluginHost::getInstance()->get_hooks(PluginHost::HOOK_QUERY_HEADLINES) as $p) { + $line = $p->hook_query_headlines($line); + } - $tpl->setVariable('ARTICLE_ID', htmlspecialchars($line['link']), true); + $tpl->setVariable('ARTICLE_ID', + htmlspecialchars($orig_guid ? $line['link'] : + get_self_url_prefix() . + "/public.php?url=" . urlencode($line['link'])), true); $tpl->setVariable('ARTICLE_LINK', htmlspecialchars($line['link']), true); $tpl->setVariable('ARTICLE_TITLE', htmlspecialchars($line['title']), true); - $tpl->setVariable('ARTICLE_EXCERPT', - truncate_string(strip_tags($line["content_preview"]), 100, '...'), true); + $tpl->setVariable('ARTICLE_EXCERPT', $line["content_preview"], true); - $content = sanitize($line["content_preview"], false, $owner_uid); + $content = sanitize($line["content"], false, $owner_uid); if ($line['note']) { $content = "
Article note: " . $line['note'] . "
" . diff --cc include/functions.php index eb011b6d,cf35d6fa..556b8a8c --- a/include/functions.php +++ b/include/functions.php @@@ -2578,8 -2579,8 +2578,10 @@@ } } - $content_query_part = "content, content as content_preview, cached_content, "; ++ + $content_query_part = "content, content AS content_preview, cached_content, "; + + if (is_numeric($feed)) { if ($feed >= 0) {