summaryrefslogtreecommitdiff
path: root/lib/atom10feed.php
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-02-18 18:20:48 +0000
committerBrion Vibber <brion@pobox.com>2010-02-18 18:20:48 +0000
commit22ff358ba8d1fd0396136e1de570d788dd0727b6 (patch)
treee53d46a094dea1c653ad7e2cb6576ac8ec17c86e /lib/atom10feed.php
parentc2ba7645359242590c8ac60b66f012110ae889ef (diff)
OStatus sub/unsub updates:
- fix for PuSH unsub verification - send Salmon notification on unsub
Diffstat (limited to 'lib/atom10feed.php')
-rw-r--r--lib/atom10feed.php11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/atom10feed.php b/lib/atom10feed.php
index 14a3beb83..5e17b20d3 100644
--- a/lib/atom10feed.php
+++ b/lib/atom10feed.php
@@ -78,7 +78,7 @@ class Atom10Feed extends XMLStringer
$this->authors = array();
$this->links = array();
$this->entries = array();
- $this->addNamespace('xmlns', 'http://www.w3.org/2005/Atom');
+ $this->addNamespace('', 'http://www.w3.org/2005/Atom');
}
/**
@@ -162,7 +162,14 @@ class Atom10Feed extends XMLStringer
{
$this->xw->startDocument('1.0', 'UTF-8');
$commonAttrs = array('xml:lang' => 'en-US');
- $commonAttrs = array_merge($commonAttrs, $this->namespaces);
+ foreach ($this->namespaces as $prefix => $uri) {
+ if ($prefix == '') {
+ $attr = 'xmlns';
+ } else {
+ $attr = 'xmlns:' . $prefix;
+ }
+ $commonAttrs[$attr] = $uri;
+ }
$this->elementStart('feed', $commonAttrs);
$this->element('id', null, $this->id);