From: Evan Prodromou Date: Sun, 2 Jan 2011 23:21:56 +0000 (-0800) Subject: let callers pass in an XMLOutputter to output to X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=e433e559f8310d405afdce20a591e0d9f6d6642c;p=quix0rs-gnu-social.git let callers pass in an XMLOutputter to output to --- diff --git a/lib/activity.php b/lib/activity.php index 8d7ae1540b..b77d53427c 100644 --- a/lib/activity.php +++ b/lib/activity.php @@ -322,6 +322,7 @@ class Activity * * @return DOMElement Atom entry */ + function toAtomEntry() { return null; @@ -330,7 +331,12 @@ class Activity function asString($namespace=false, $author=true, $source=false) { $xs = new XMLStringer(true); + $this->outputTo($xs, $namespace, $author, $source); + return $xs->getString(); + } + function outputTo($xs, $namespace=false, $author=true, $source=false) + { if ($namespace) { $attrs = array('xmlns' => 'http://www.w3.org/2005/Atom', 'xmlns:thr' => 'http://purl.org/syndication/thread/1.0', @@ -518,9 +524,7 @@ class Activity $xs->elementEnd('entry'); - $str = $xs->getString(); - - return $str; + return; } private function _child($element, $tag, $namespace=self::SPEC)