Forum

Thread tagged as: Question, Add-on-development

XML RSS feed from Perch

Hello,

We need help to develop a small script that can generate an XML RSS feed from select fields of our Perch database stored in Json format. (required format https://www.fieldtripper.com/fieldtrip_rss )

It shouldn't be a major task but it will require * transforming the editor code (Markitup, used by Perch) into regular HTML, such as p. for paragraph and URL links * decoding "weird" characters (e.g., apostrophes) that become warped as a result from utf-8 vs other encodings

Anybody with the time and skills available to help? Please get in touch to discuss a quote info@60by80.com

Michael Fuchs

Michael Fuchs 0 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

You can do that with a simple template.

Here's an example from Blog, but the principal is the same. https://docs.grabaperch.com/video/v/create-a-blog-rss-feed/

Thanks for responding Drew.

We're still using Perch version 1. Would it be a new feature that you can use multiple templates for one type of content? As I understand it, as soon as I add a template, I will need to fill out its content in Perch. What we would need, is being able to add a template that picks up the same content as a different already existing template.

We are having a lot of content already in Perch, using HTML templates. Now we want to add new XML templates for that very same content. Is that possible somehow? Or do we need to update from version 1 to 2 for that feature?

Drew McLellan

Drew McLellan 2638 points
Perch Support

You can do that in Perch 1 using the perch_content_custom() function with its 'template' option.

That said, support for Perch 1 ends in a few months. If you're adding new features to your site you should plan to upgrade. I wouldn't recommend upgrading for every site - some are ticking along just fine and might sooner be replaced with a new site eventually - but for any site you're actively growing and developing it makes real sense to upgrade.

Thank you so much Drew, that did the job. Forgot to return here and thank you.