User Tools

Site Tools


doc:tips:change-the-output-of-the-rss-or-atom-feed

Change the output of the RSS or Atom feed

This section describes how you can customize the output of entries and comments in the RSS or Atom feed.

FAQ

Q: Where are the templates for RSS and Atom in FlatPress?

A: /fp-interface/sharedtpls (rss.tpl, atom.tpl, comment-rss.tpl, comment-atom.tpl)

Syntax

Example:

{$content|tag:the_content|strip_tags|strip|truncate:180:"...":true|escape}

strip_tags: Removes all HTML and PHP tags from the text to ensure that the content is plain text.

strip: Removes unnecessary spaces or line breaks at the beginning and end of the text as well as superfluous spaces within the content.

truncate:180:“…”:true: Truncates the text to 180 characters. If the text is truncated, … is added at the end. The additional parameter true ensures that words are not truncated in the middle.

escape: Masks special characters in HTML to prevent security problems such as cross-site scripting (XSS). For example, characters such as <, > and & are converted to &lt;, &gt; and &amp;.

doc/tips/change-the-output-of-the-rss-or-atom-feed.txt · Last modified: 2025/01/01 22:42 by fraenkiman

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki