blob: 236cca3038901e65137e0f2eb5f0581aa9c9f6db (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
<?php
$opml_array = array(
'head' => array(
'title' => FreshRSS_Context::$system_conf->title,
'dateCreated' => date('D, d M Y H:i:s')
),
'body' => array()
);
foreach ($this->categories as $key => $cat) {
$opml_array['body'][$key] = array(
'text' => $cat['name'],
'@outlines' => array()
);
foreach ($cat['feeds'] as $feed) {
$opml_array['body'][$key]['@outlines'][] = array(
'text' => htmlspecialchars_decode($feed->name()),
'type' => 'rss',
'xmlUrl' => htmlspecialchars_decode($feed->url()),
'htmlUrl' => htmlspecialchars_decode($feed->website()),
'description' => htmlspecialchars_decode($feed->description()),
);
}
}
echo libopml_render($opml_array);
|