blob: 94d3cd4f6ab0463e2c08e1a6474002ffbb16a7f8 (
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
<?php
header("Content-Type: application/xml");
echo('<?xml version="1.0" encoding="UTF-8" ?>');
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/markdown.php";
$Parsedown = new Parsedown();
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/articles/getlist.php";
$list = getArticlesList();
?>
<rss version="2.0">
<!--
This is UnchainedTech's RSS feed!
Only the last 10 articles are shown to preserve your and my bandwidth.
UnchainedTech is
(c) UnchainedTech Authors, All rights reserved.
-->
<channel>
<title>UnchainedTech</title>
<link>https://unchainedtech.minteck.ro.lt</link>
<description>UnchainedTech is a tech-centric blog written by two people on their free time</description>
<copyright><?= date('Y') ?> UnchainedTech Authors, All rights reserved.</copyright>
<language>en-us</language>
<?php $index = 0; foreach ($list as $item): ?>
<?php if ($index < 10 && !$item["admin"]): ?>
<item>
<title><?= $item["title"] ?></title>
<link>https://unchainedtech.minteck.ro.lt/article/<?= $item["id"] ?></link>
<description><?= $item["content"]["full"] ?></description>
<pubdate><?php
$dt = DateTime::createFromFormat('YmdHis', $item["date"] . "000000");
echo $dt->format("D, d M Y H:i:s T");
?></pubdate>
</item>
<?php endif; ?>
<?php $index++; endforeach; ?>
</channel>
</rss>
|