From: Friendika Date: Wed, 12 Jan 2011 21:21:37 +0000 (-0800) Subject: preserve body content in feed to extract microformat stuff X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=89a28bf0f7b43c4bafdfde794066aefe705efa89;p=friendica.git preserve body content in feed to extract microformat stuff --- diff --git a/include/items.php b/include/items.php index d267abe075..4c18938b0a 100644 --- a/include/items.php +++ b/include/items.php @@ -452,6 +452,8 @@ function get_atom_elements($feed,$item) { $body = $rawobj[0]['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['content'][0]['data']; if(! $body) $body = $rawobj[0]['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['summary'][0]['data']; + // preserve a copy of the original body content in case we later need to parse out any microformat information, e.g. events + $res['object'] .= '' . xmlify($body) . '' . "\n"; if(strpos($body,'<')) { $body = preg_replace('#]+>.+?' . 'http://www.youtube.com/((?:v|cp)/[A-Za-z0-9\-_=]+).+?#s', @@ -489,6 +491,8 @@ function get_atom_elements($feed,$item) { $body = $rawobj[0]['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['content'][0]['data']; if(! $body) $body = $rawobj[0]['child'][SIMPLEPIE_NAMESPACE_ATOM_10]['summary'][0]['data']; + // preserve a copy of the original body content in case we later need to parse out any microformat information, e.g. events + $res['object'] .= '' . xmlify($body) . '' . "\n"; if(strpos($body,'<')) { $body = preg_replace('#]+>.+?' . 'http://www.youtube.com/((?:v|cp)/[A-Za-z0-9\-_=]+).+?#s',