From 97b6231468bf11046e29f368e113ea3865639c12 Mon Sep 17 00:00:00 2001 From: Bernhard Posselt Date: Mon, 15 Oct 2012 22:08:07 +0200 Subject: show feedtitle when not showing a feed but folder/starred/new articles --- templates/part.items.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'templates/part.items.php') diff --git a/templates/part.items.php b/templates/part.items.php index d331f5172..bcbc8da37 100644 --- a/templates/part.items.php +++ b/templates/part.items.php @@ -1,6 +1,7 @@ '; foreach($items as $item) { @@ -31,13 +32,15 @@ foreach($items as $item) { echo ''; echo '

' . htmlspecialchars($item->getTitle(), ENT_QUOTES, 'UTF-8') . '

'; - -// if ($lastViewedFeedType !== OCA\News\FeedType::FEED) { - echo '
' . $l->t('from') . ' ' . $item->getFeedTitle() . '
'; -// } + + if ((int)$lastViewedFeedType !== OCA\News\FeedType::FEED) { + $feedTitle = ' ' . $l->t('from') . ' ' . $item->getFeedTitle() . ''; + } else { + $feedTitle = ''; + } if(($item->getAuthor() !== null) && (trim($item->getAuthor()) != '')) { - echo '

'. $l->t('by') . ' ' . htmlspecialchars($item->getAuthor(), ENT_QUOTES, 'UTF-8') . '

'; + echo '

'. $feedTitle . $l->t('by') . ' ' . htmlspecialchars($item->getAuthor(), ENT_QUOTES, 'UTF-8') . '

'; } echo '
' . $item->getBody() . '
'; -- cgit v1.2.3