Browse Source

Merge pull request #1564 from aledeg/open-site-shortcut

Add support for a new shortcut in reader view
Alexandre Alapetite 8 years ago
parent
commit
8a04454655
3 changed files with 3 additions and 3 deletions
  1. 1 1
      app/views/index/normal.phtml
  2. 1 1
      app/views/index/reader.phtml
  3. 1 1
      p/scripts/main.js

+ 1 - 1
app/views/index/normal.phtml

@@ -66,7 +66,7 @@ if (!empty($this->entries)) {
 
 		?><div class="flux_content">
 			<div class="content <?php echo $content_width; ?>">
-				<h1 class="title"><a target="_blank" rel="noreferrer" href="<?php echo $this->entry->link(); ?>"><?php echo $this->entry->title(); ?></a></h1>
+				<h1 class="title"><a target="_blank" rel="noreferrer" class="go_website" href="<?php echo $this->entry->link(); ?>"><?php echo $this->entry->title(); ?></a></h1>
 				<?php
 					$author = $this->entry->author();
 					echo $author != '' ? '<div class="author">' . _t('gen.short.by_author', $author) . '</div>' : '',

+ 1 - 1
app/views/index/reader.phtml

@@ -19,7 +19,7 @@ if (!empty($this->entries)) {
 					$feed = FreshRSS_CategoryDAO::findFeed($this->categories, $item->feed());	//We most likely already have the feed object in cache
 					if (empty($feed)) $feed = $item->feed(true);
 				?>
-				<a href="<?php echo $item->link(); ?>">
+				<a target="_blank" rel="noreferrer" class="go_website" href="<?php echo $item->link(); ?>">
 					<img class="favicon" src="<?php echo $feed->favicon(); ?>" alt="✇" /> <span><?php echo $feed->name(); ?></span>
 				</a>
 				<h1 class="title"><?php echo $item->title(); ?></h1>

+ 1 - 1
p/scripts/main.js

@@ -664,7 +664,7 @@ function init_shortcuts() {
 	});
 
 	shortcut.add(shortcuts.go_website, function () {
-		var url_website = $('.flux.current > .flux_header > .title > a').attr("href");
+		var url_website = $('.flux.current a.go_website').attr("href");
 
 		if (context.auto_mark_site) {
 			$(".flux.current").each(function () {