As I know, there are no length restrictions. 2
In RSS 0.91, various elements are limited to 500 or 100 characters. There can be no more than 15 <item> s in 0.91 <channel>. In RSS 0.92 and above, there are no restrictions on line length or XML level. Processors can impose their own limits, and generators can have preferences that say no more than a certain number of <item> s can appear in a channel or that lines are limited in length.
Rss 2.0
For all elements defined in the RSS specification that enclose character data, the text should be interpreted as plain text with the exception of the element description element, which should be a presentation as HTML. All of these items should not contain baby items.
There is no limit to the length of character data that can be contained in an RSS element.
So you want to cut text somewhere and add ...? In this case, just use substr.
$description = substr($description, 0, 250)."...";
Replace 250 with your desired size.
tildy source share