Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-02-08 09:14:42

Boby Dimitrov
Member
From: Sofia, Bulgaria
Registered: 2004-09-27
Posts: 76
Website

RSS to include excerpt + body

Somehow I’ve got the feeling I’ve already asked that, but I couldn’t find the topic…

I’d like the RSS feed to include both excerpt AND body content.

Why? It seems I’ve been using the excerpt field in a improper way… The way I thought it was supposed to work was that excerpt is kinda introduction to the full post, a foreword. But it seems TXP logic is that excerpt must be completely independent of body. It has to double the body content in some part…

Anyway, where do I have to start hacking?

Offline

#2 2007-03-01 21:07:41

The-Exit
Member
From: Berlin
Registered: 2005-07-16
Posts: 175
Website

Re: RSS to include excerpt + body

well, this is a problem, i have, too.

i hacked the rss.php in textpattern > publish with this hack:

# if ($syndicate_body_or_excerpt) {
# short feed: use body as summary if there's no excerpt
#	if (!trim($summary))
#	$summary = $content;
#	$content = '';
# }

$content=$summary.$content;

but i would rather prefer a plugin to do this job. but so far i have not found any plugin for this!

(edited to take last paragraph out of code box. -Els)

Last edited by els (2007-03-01 23:02:01)

Offline

#3 2007-03-02 09:28:37

Boby Dimitrov
Member
From: Sofia, Bulgaria
Registered: 2004-09-27
Posts: 76
Website

Re: RSS to include excerpt + body

Thanks for the fix! I was looking for a plugin myself, but found none.

Offline

#4 2007-03-02 23:02:50

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: RSS to include excerpt + body

Boby

rather than hacking existing code, if you are running on Txp 4.0.4 you could try writing a simple plugin to do this by making use of the _l10n_tag_feeds event.


Steve

Offline

#5 2007-03-03 01:33:46

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: RSS to include excerpt + body

That doesn’t exist.

Offline

#6 2007-03-04 15:03:50

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: RSS to include excerpt + body

Mary wrote:

That doesn’t exist.

Doh! Absolutely correct Mary, I pasted my own routine’s name rather than the event(s); thanks.

Boby, make that rss_entry or atom_entry and it might be closer to reality.


Steve

Offline

#7 2007-03-05 08:06:18

Boby Dimitrov
Member
From: Sofia, Bulgaria
Registered: 2004-09-27
Posts: 76
Website

Re: RSS to include excerpt + body

Thanks for the idea, Steve :) . I’m far from writing plugins (or any programing code, for that matter), so I’ll stick with the fix for now.

Offline

Board footer

Powered by FluxBB