inside_item = true; elseif ($name == "IMAGE") $this->inside_item = true; } function tag_close($parser, $tagName, $attrs=''){ global $current_tag; if ($tagName == "ITEM") { $this->items[] = array("title" => $this->item['TITLE'], "description" => $this->item['DESCRIPTION'], "link" => $this->item['LINK']); $this->item['TITLE'] = ""; $this->item['DESCRIPTION'] = ""; $this->item['LINK'] = ""; $this->inside_item = false; } elseif ($tagName == "IMAGE") { $this->item['TITLE'] = ""; $this->item['DESCRIPTION'] = ""; $this->item['LINK'] = ""; $this->inside_item = false; } elseif ($tagName == "CHANNEL") { $this->channel = array("title" => $this->title, "description" => $this->description, "link" => $this->link, "date" => $this->date, "divers" => $this->divers); $this->title = ""; $this->description = ""; $this->link = ""; $this->divers = ""; $this->date = ""; } } function cdata($parser, $data){ global $current_tag; if ($this->inside_item) { if (empty($this->item[$current_tag])) $this->item[$current_tag] = ''; if ($current_tag == 'LINK') { if (trim($data)) $this->item[$current_tag] = trim($data); } else { $this->item[$current_tag] .= trim($data); } } else { switch ($current_tag) { case "TITLE": if (trim($data)) $this->title .= " " . trim($data); break; case "DESCRIPTION": if (trim($data)) $this->description .= trim($data); break; case "LINK": if (trim($data)) $this->link = trim($data); break; case "DC:DATE": if (trim($data)) $this->date .= " " . trim($data); default: if (trim($data)) $this->divers .= " " . $current_tag."/".$data; break; } } } // characterData } // $Log: not supported by cvs2svn $ // Revision 1.6 2004/05/18 16:18:36 rurban // AutoSplit at subpage seperators // RssFeed stability fix for empty feeds or broken connections // // Revision 1.5 2004/04/26 20:44:34 rurban // locking table specific for better databases // // Revision 1.4 2004/04/18 01:11:51 rurban // more numeric pagename fixes. // fixed action=upload with merge conflict warnings. // charset changed from constant to global (dynamic utf-8 switching) // // For emacs users // Local Variables: // mode: php // tab-width: 8 // c-basic-offset: 4 // c-hanging-comment-ender-p: nil // indent-tabs-mode: nil // End: ?>