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=810304159e2ba5a7b68aef45480ba822ec3fce2b;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)