Editing article titles before they're stored

Development-related discussion, including bundled plugins
MrChick
Bear Rating Trainee
Bear Rating Trainee
Posts: 1
Joined: 19 Apr 2013, 04:52

Editing article titles before they're stored

Postby MrChick » 19 Apr 2013, 05:48

Hi,

I want to prepend the author of an article in front of the title of said article.

Example: Title is "How to do something awesome", posted by author "Max" on feed Foobar which has articles of multiple authors, like Max, Franz and Heinrich.
I want this title to be changed to "[Max] How to do something awesome".
I'd prefer to do it as a plugin instead of hacking my tt-rss installation but I seem to run into a dead end.

I tried to approach it with hooking FEED_PARSED, but it seems that SimplePie only has getters on that info and no setters.


Any idea how I should approach this problem?

Saliency
Bear Rating Trainee
Bear Rating Trainee
Posts: 49
Joined: 27 Mar 2013, 20:05

Re: Editing article titles before they're stored

Postby Saliency » 20 Apr 2013, 00:12

I don't know if it is the best way but one way you could do it which would be easy is to add an insert trigger to the DB.
You also can blast all your old data while you are at it.


Return to “Development”

Who is online

Users browsing this forum: No registered users and 2 guests