summaryrefslogtreecommitdiff
path: root/actions/twitapistatuses.php
diff options
context:
space:
mode:
authorzach <zach@copley.name>2008-07-16 15:18:47 -0400
committerzach <zach@copley.name>2008-07-16 15:18:47 -0400
commitc998c7c60180cecbb55435629307de6f00bd637b (patch)
tree65ac3cf5c91ab88d9b8b0c3b1adace73d2d57d15 /actions/twitapistatuses.php
parent7b2367164ea8065754db9c92ec10dfb9ac685527 (diff)
Twitter-compatible API: public_timeline.rss really works now
darcs-hash:20080716191847-ca946-9a75dd3aa07974408b269b31d1de3e49c5ae2a72.gz
Diffstat (limited to 'actions/twitapistatuses.php')
-rw-r--r--actions/twitapistatuses.php17
1 files changed, 9 insertions, 8 deletions
diff --git a/actions/twitapistatuses.php b/actions/twitapistatuses.php
index d1f957942..3a495a129 100644
--- a/actions/twitapistatuses.php
+++ b/actions/twitapistatuses.php
@@ -70,25 +70,26 @@ class TwitapistatusesAction extends TwitterapiAction {
common_end_xml();
} elseif ($apidata['content-type'] == 'rss') {
-
- //header('Content-Type: application/xml; charset=utf-8');
header("Content-Type: application/rss+xml; charset=utf-8");
$this->init_twitter_rss();
+ $sitename = common_config('site', 'name');
+ $siteserver = common_config('site', 'server');
+
common_element_start('channel');
- common_element('title', NULL, 'Identi.ca public timeline');
- common_element('link', NULL, 'http://www.identi.ca');
- common_element('description', NULL, 'Identi.ca updates from everyone!');
+ common_element('title', NULL, "$sitename public timeline");
+ common_element('link', NULL, "http://$siteserver");
+ common_element('description', NULL, "$sitename updates from everyone!");
common_element('language', NULL, 'en-us');
- common_element('ttl', NULL, '40'); // 40 what?
+ common_element('ttl', NULL, '40');
if ($cnt > 0) {
for ($i = 0; $i < 20; $i++) {
if ($notice->fetch()) {
- $twitter_status = $this->twitter_status_array($notice);
- $this->show_twitter_rss_item($twitter_status);
+ $entry = $this->twitter_rss_entry_array($notice);
+ $this->show_twitter_rss_item($entry);
} else {
// shouldn't happen!
break;