';
+ $entryEnclosures = '';
+ if(isset($item['enclosures'])){
+ $entryEnclosures = '
';
}
$entries .= <<
EOD;
diff --git a/formats/MrssFormat.php b/formats/MrssFormat.php
index 19c703e..a7573f5 100644
--- a/formats/MrssFormat.php
+++ b/formats/MrssFormat.php
@@ -31,9 +31,23 @@ class MrssFormat extends FormatAbstract {
$itemTimestamp = isset($item['timestamp']) ? $this->xml_encode(date(DATE_RFC2822, $item['timestamp'])) : '';
$itemContent = isset($item['content']) ? $this->xml_encode($this->sanitizeHtml($item['content'])) : '';
- $entryEnclosure = '';
- if(isset($item['enclosure'])){
- $entryEnclosure = '';
+ $entryEnclosuresWarning = '';
+ $entryEnclosures = '';
+ if(isset($item['enclosures'])){
+ $entryEnclosures .= '';
+
+ if(count($item['enclosures']) > 1){
+ $entryEnclosures .= PHP_EOL;
+ $entryEnclosuresWarning = '<br>Warning:
+Some media files might not be shown to you. Consider using the ATOM format instead!';
+ foreach($item['enclosures'] as $enclosure){
+ $entryEnclosures .= ''
+ . PHP_EOL;
+ }
+ }
}
$items .= <<{$itemUri}
{$itemUri}
{$itemTimestamp}
- {$itemContent}
+ {$itemContent}{$entryEnclosuresWarning}
{$itemAuthor}
- {$entryEnclosure}
+ {$entryEnclosures}
EOD;