Plugin: Article Headline Toggle

Post plugins and custom CSS snippets here
wn_
Bear Rating Trainee
Bear Rating Trainee
Posts: 13
Joined: 14 Apr 2013, 01:07

Plugin: Article Headline Toggle

Postby wn_ » 16 Apr 2013, 18:41

A simple Tiny Tiny RSS plugin to toggle article visibility by clicking on the headline (rather than the small [-] image or using a keyboard shortcut).

Made under v1.7.8, with "Combined feed display" and "Automatically expand articles in combined mode" preferences enabled.

This is my first stab at a TTRSS plugin, so feedback is certainly welcome (e.g. do it this way instead).

Known Issues
Doesn't work great without the preference combination mentioned above. This will be fixed in the next release.

Installation
1. Copy the article_headline_toggle directory to the plugins directory of your Tiny Tiny RSS installation.
2. Go to Preferences / Plugins and enable article_headline_toggle.

Changes
2013-04-18 (1.1):
Removing currently-unused $link for compatibility with TTRSS 1.7.9
2013-04-14 (1.0):
* First release

Download: https://github.com/supahgreg/ttrss-arti ... master.zip
Source: https://github.com/supahgreg/ttrss-arti ... ine-toggle
Issue Tracker: https://github.com/supahgreg/ttrss-arti ... gle/issues
Last edited by wn_ on 18 Apr 2013, 15:33, edited 1 time in total.

jakob42
Bear Rating Trainee
Bear Rating Trainee
Posts: 15
Joined: 20 Mar 2013, 16:43

Re: Plugin: Article Headline Toggle

Postby jakob42 » 16 Apr 2013, 22:34

Nice, thanks for that, missed this actually.

Napkin
Bear Rating Trainee
Bear Rating Trainee
Posts: 21
Joined: 29 Mar 2013, 01:07

Re: Plugin: Article Headline Toggle

Postby Napkin » 16 Apr 2013, 22:57

Agreed, very nice, thank you!
Last edited by Napkin on 17 Apr 2013, 12:38, edited 1 time in total.

macfly
Bear Rating Disaster
Bear Rating Disaster
Posts: 82
Joined: 27 Mar 2013, 23:07

Re: Plugin: Article Headline Toggle

Postby macfly » 17 Apr 2013, 12:27

*very* usefull. thank you!

jakob42
Bear Rating Trainee
Bear Rating Trainee
Posts: 15
Joined: 20 Mar 2013, 16:43

Re: Plugin: Article Headline Toggle

Postby jakob42 » 18 Apr 2013, 10:17

To be , you'll need to remove the line "$this->link = $host->get_link();", which isn't used by your plugin anyways.

Che
Bear Rating Trainee
Bear Rating Trainee
Posts: 4
Joined: 17 Apr 2013, 17:21

Re: Plugin: Article Headline Toggle

Postby Che » 07 May 2013, 11:13

Doesn't work for me:

error messages after activating the plugin:

Warning: Cannot modify header information - headers already sent by (output started at /home/www/web206/html/ttrss/plugins/article_headline_toggle/init.php:81) in html/ttrss/include/functions.php on line 2875

Version: 1.7.8

wn_
Bear Rating Trainee
Bear Rating Trainee
Posts: 13
Joined: 14 Apr 2013, 01:07

Re: Plugin: Article Headline Toggle

Postby wn_ » 07 May 2013, 15:27


Che
Bear Rating Trainee
Bear Rating Trainee
Posts: 4
Joined: 17 Apr 2013, 17:21

Re: Plugin: Article Headline Toggle

Postby Che » 07 May 2013, 17:31

The error is gone, thanks.

Maybe I misunderstand the plugin, but when I click on header I see the preview of an article. When I click again on the header again, the article will opened in a new browser tab , instead of closing the preview. :(

macfly
Bear Rating Disaster
Bear Rating Disaster
Posts: 82
Joined: 27 Mar 2013, 23:07

Re: Plugin: Article Headline Toggle

Postby macfly » 07 May 2013, 17:52

when the article is expanded (you see a preview of the article), it depends, if you click on the headline without text, or on the headline-text.

- click on the headline without text: the article will collapse
- click on the headline-text: open the article in a new Window.

Che
Bear Rating Trainee
Bear Rating Trainee
Posts: 4
Joined: 17 Apr 2013, 17:21

Re: Plugin: Article Headline Toggle

Postby Che » 07 May 2013, 18:59

Thanks for the information and your work.

gitawego
Bear Rating Trainee
Bear Rating Trainee
Posts: 9
Joined: 08 May 2013, 00:35

Re: Plugin: Article Headline Toggle

Postby gitawego » 08 May 2013, 00:36

that's THE plugin that I'm looking for :)
thanks a lot for your hard work!

daledavies
Bear Rating Trainee
Bear Rating Trainee
Posts: 9
Joined: 27 Apr 2013, 16:45
Contact:

Re: Plugin: Article Headline Toggle

Postby daledavies » 09 May 2013, 01:54

Works perfectly, thanks :-)

IvanRaide
Bear Rating Trainee
Bear Rating Trainee
Posts: 9
Joined: 10 May 2013, 06:40

Re: Plugin: Article Headline Toggle

Postby IvanRaide » 10 May 2013, 07:55

Would it be possible to make this plugin (or a similar one) toggle the expanded view on the title only, and only load the article when clicking in the body of an expanded article?
Similar to what "Che" was saying "click on the header, see the preview, click again on the header, close the preview/click on the preview body, load the article" ??

wn_
Bear Rating Trainee
Bear Rating Trainee
Posts: 13
Joined: 14 Apr 2013, 01:07

Re: Plugin: Article Headline Toggle

Postby wn_ » 10 May 2013, 17:28


IvanRaide
Bear Rating Trainee
Bear Rating Trainee
Posts: 9
Joined: 10 May 2013, 06:40

Re: Plugin: Article Headline Toggle

Postby IvanRaide » 10 May 2013, 21:20

Is there any docs/information on the layout/structure of how things work? Looking at your plugin, I started looking at viewfeed.js in cdmClicked function (and see the if CTRLKEY openArticleInNewWindow call for example) but just not sure I understand it enough to start poking around.


Return to “Themes and plugins”

Who is online

Users browsing this forum: No registered users and 6 guests