Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: [request] Article Image as Feed
Christian,
I actually thought of that as soon as I made this. This is the first time I’ve messed with feeds so I thought I’d see what problems came back first.
Last edited by hakjoon (2007-05-03 13:29:21)
Shoving is the answer – pusher robot
Offline
Re: [request] Article Image as Feed
Hi Patrick,
yeah, ive installed it…works fine, i think this less amount of code will make some TXP’s very happy.
No, Problems there, tested it in 3 different Feedreaders, ive also tested the feed in the Feed Validator and it works fine.
I dont know what you could edit, maybe the form can be automaticly generated, but all other things come from the famous textile-forms, so we all now have the ability to edit our feed-output.
Thank you!!! Just wrote a Blogpost about it….
Offline
#15 2007-05-04 07:26:47
- alexandra
- Member
- From: Cologne, Germany
- Registered: 2004-04-02
- Posts: 1,370
Re: [request] Article Image as Feed
grafzahl schrieb:
Thank you!!! Just wrote a Blogpost about it….
here is the link to the posting – article is in german but patrick will find some probably intersting codemodification in it?
Offline
Re: [request] Article Image as Feed
Took a look at the post. Google translates things pretty weird :)
That’s what i was thinking of doing. I’ll probably just replace this plugin with something that let’s you specify feed content. Basically what Christian did. I just need to check for any weirdness with excerpts.
Shoving is the answer – pusher robot
Offline
Re: [request] Article Image as Feed
hi
this is a lovely plugin! it works just great!
the only problem i have is with excerpts.
i split up my blog postings in excerpt and body (but the body does not contain the text entered into the excerpt).
i get this behavior:
if the article exists only of the body: the plugin works great.
if the article is excert + body, i just get the excerpt in the feed, but the plugin does not work :(
Offline
Re: [request] Article Image as Feed
You can fix the problem with the excerpts with this plugin-code:
register_callback(‘hak_feed_append’, ‘atom_entry’); register_callback(‘hak_feed_append’, ‘rss_entry’); function hak_feed_append($event, $step) { global $thisarticle; $form = fetch_form(‘feed_append’); $thisarticle[‘body’] = parse($form); $thisarticle[‘excerpt’] = parse($form); }
This replaces the body and (if its there) the excerpt with the parsed “feed-append”-form…so both are overwritten and you can catch the excerpt (if you like) manually with <txp:if_excerpt> or something like this…also plugins work fine on the form…
Last edited by grafzahl (2007-05-04 21:46:29)
Offline
Re: [request] Article Image as Feed
well, now i get kind of doubled entries, see here
Offline
Re: [request] Article Image as Feed
TXP does some stuff with excerpts on it’s own after the callback runs. That’s the behavior I wanted to check on.
I think if you turn off Syndicate article excerpt (default is article body)? in Admin -> Preferences -> Advanced -> Publish section you can handle the excerpts yourself using <txp:if_excerpt>
like Christian described.
Shoving is the answer – pusher robot
Offline
Re: [request] Article Image as Feed
Yeah i descripted this in my blogentry to, you need to switch off the intern “Excerpt before body” in the txp-backend.
Well patrick, never thought that this effect can be generated by 7 lines of code :)
Offline
Re: [request] Article Image as Feed
grafzahl wrote:
Yeah i descripted this in my blogentry to, you need to switch off the intern “Excerpt before body” in the txp-backend.
I think my Google translation kind of mangled that part :)
Well patrick, never thought that this effect can be generated by 7 lines of code :)
I know, I think this is the shortest plugin I’ve written. I’ll work on an update that implements your change, unless you want to do it. After all the code is yours as much as mine.
Shoving is the answer – pusher robot
Offline
Re: [request] Article Image as Feed
Hi there,
I really like this plugin, really does what I need on my latest project… but not 100%.
I succesfully send a feed from hbktv.se to hbk.se (shown on the left side under the headline HBK TV)
The problem: There´s only one section that include article image in my feed
Working section: Malservice
Non-working: article
Combined (as I want it to be): Both article and Malservice does include the image from section malservice but not article
The plugin is activated.
My form looks like this (Misc):
< txp:article_image thumbnail=“1” / >
< txp:excerpt / >
Any ideas where to look? Or have I missed somethin vital earlier in the thread?
Offline
Re: [request] Article Image as Feed
I don’t see any reason why that shouldn’t work. Do the images in /article/ have thumbnails? That’s the only thing I can think of.
Shoving is the answer – pusher robot
Offline