62
|
62
|
|
// 'r' » RFC 2822 formatted date (Example: Thu, 21 Dec 2000 16:01:07 +0200)
|
63
|
63
|
|
$date = date ('r', strtotime ($post['created']));
|
64
|
64
|
|
|
65
|
|
- |
$item->addChild ('title', htmlspecialchars ($post['title']));
|
66
|
|
- |
$item->addChild ('description', htmlspecialchars ($description));
|
67
|
|
- |
$item->addChild ('link', $link);
|
68
|
|
- |
$item->addChild ('freepostLink', $freepost_link);
|
69
|
|
- |
$item->addChild ('pubDate', $date);
|
70
|
|
- |
$item->addChild ('author', htmlspecialchars ($post['username']));
|
|
65
|
+ |
/**
|
|
66
|
+ |
* It's recommended that you provide the guid, and if possible make it a
|
|
67
|
+ |
* permalink. This enables aggregators to not repeat items, even if there
|
|
68
|
+ |
* have been editing changes.
|
|
69
|
+ |
*/
|
|
70
|
+ |
$item->addChild ('guid', $post['hashId']);
|
|
71
|
+ |
|
|
72
|
+ |
/**
|
|
73
|
+ |
* Optional. If set to true, the reader may assume that it is a permalink
|
|
74
|
+ |
* to the item (a url that points to the full item described by the <item>
|
|
75
|
+ |
* element). The default value is true. If set to false, the guid may not
|
|
76
|
+ |
* be assumed to be a url.
|
|
77
|
+ |
*/
|
|
78
|
+ |
$item->addChild ('isPermaLink', false);
|
|
79
|
+ |
|
|
80
|
+ |
$item->addChild ('title', htmlspecialchars ($post['title']));
|
|
81
|
+ |
$item->addChild ('description', htmlspecialchars ($description));
|
|
82
|
+ |
$item->addChild ('link', $link);
|
|
83
|
+ |
$item->addChild ('freepostLink', $freepost_link);
|
|
84
|
+ |
$item->addChild ('pubDate', $date);
|
|
85
|
+ |
$item->addChild ('author', htmlspecialchars ($post['username']));
|
71
|
86
|
|
}
|
72
|
87
|
|
|
73
|
88
|
|
// Output RSS
|