Things you should know about when working with RSS

If you have created additional (non official) documentation or tutorials or something like that please post this here
Post Reply
User avatar
Jensensen
Posts: 3000
Joined: Tue 17. Oct 2006, 21:11
Location: auf der mlauer

Things you should know about when working with RSS

Post by Jensensen »

[mode: your site's delivering rss feeds]

Let's assume that you --> ONLY have the source code in the --> header of the page like the following:

Code: Select all

<link rel="alternate" type="application/rss+xml" title="COMPANY main RSS feed" href="content/rss/RSS2.0-default_feed.xml" />
In that case you get a big problem: Because even if you publish many new articles a day, the RSS XML file(s) won't be updated automatically!

Solution:
A)
Run the RSS-update-script once you've edited articles --> www. SERVER.tld/feeds.php?feed=all

B) Add source code to your template(s):
B.1) --> [RSS all]RSS-Feed[/RSS] or
B.2) --> <a href="feeds.php?feed=all" target="_blank" class="phpwcmsRSSLink">RSS-Feed</a>

Keep in mind when no site visitors clicking the link by day, the crawlers, spiders, robots do it by night. :wink:
(by which the xmls are updated)

Read more about RSS replacement tags: http://www.phpwcms-docu.de/system_tags.phtml
{so_much} | Knick-Knack. | GitHub
Umlaute im URL sind meistens immer Kacke.
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: Things you should know about when working with RSS

Post by update »

for compatibility issues you should add a second line:

Code: Select all

<link rel="alternate" type="application/rss+xml" title="Our daily newsfeed" href="feeds.php?feed=news" />
<link rel="alternate" type="text/xml" title="Our daily newsfeed" href="feeds.php?feed=news" />
See the other difference? It's the href="feeds.php?feed=news". This is working too if you name your RSS feed properly within the template (otherwise the default mentioned by you will take place ;).
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
Jensensen
Posts: 3000
Joined: Tue 17. Oct 2006, 21:11
Location: auf der mlauer

Re: Things you should know about when working with RSS

Post by Jensensen »

:oops: Oops, yes, right you are! Good to know, nice to have, also. Thank you.

But I'm wondering because when using the method you mentioned above, the XML file will be renewed with every page call!?¿ :roll: :shock: This could run into some rather time related issues, isn't it?

claus wrote:for compatibility issues ...
What do you mean by that?
{so_much} | Knick-Knack. | GitHub
Umlaute im URL sind meistens immer Kacke.
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: Things you should know about when working with RSS

Post by update »

If this is really the case then I'll switch to your solution
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
Oliver Georgi
Site Admin
Posts: 9905
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: Things you should know about when working with RSS

Post by Oliver Georgi »

phpwcms is using build-in caching. And you always have to link against feeds.php.

The RSS cache timeout is defined in seconds in feeds.ini.php: "cacheTTL = 3600" (1 hour by default).

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
Post Reply