Changeset 14613 for branches/dev


Ignore:
Timestamp:
2007/06/14 00:55:35 (19 years ago)
Author:
adati
Message:
 
Location:
branches/dev/html/test/adachi/LLReader
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/dev/html/test/adachi/LLReader/LLReader.php

    r14612 r14613  
    77    private $plugins; 
    88    private $feeds; 
     9    private $update_feeds; 
    910     
    1011    public function __construct($config){ 
     
    1213        $this->plugins = array(); 
    1314        $this->feeds   = array(); 
     15        $this->update_feeds = array(); 
    1416    } 
    1517     
     
    8385     
    8486    public function get_feeds () { 
     87        if ( count($this->update_feeds) > 0 ) { 
     88            return $this->update_feeds; 
     89        } 
    8590        return $this->feeds; 
    8691    } 
  • branches/dev/html/test/adachi/LLReader/LLReader/Plugin/Filter/SearchEntry2Feed.php

    r14612 r14613  
    3131    } 
    3232     
    33     private function entry2feed ($llr, $feed, $entry) { 
     33    private function entry2feed ($llr, $feed, $entries) { 
     34        $output = "<?xml version=\"1.0\"?> 
     35                    <rss version=\"2.0\"> 
     36                        <channel> 
     37                            <title>{$feed->title}</title> 
     38                            <link>http://www.tracypeterson.com/RSS/RSS.php</link> 
     39                            <description>$feed->description</description> 
     40                            <language>$feed->language</language> 
     41                            <pubDate>$feed->date</pubDate> 
     42                            <lastBuildDate>$feed->lastBuildDate</lastBuildDate> 
     43                            <docs>http://someurl.com</docs> 
     44                            <managingEditor>[email protected]</managingEditor> 
     45                            <webMaster>[email protected]</webMaster> 
     46                    "; 
     47                     
     48        foreach ($entries as $entry) 
     49        { 
     50            $output .= "<item><title>" . $entry->title . "</title> 
     51                            <link>" . $entry->link . "</link> 
     52                             
     53        <description>".htmlentities(strip_tags($line['description']))."</description> 
     54                        </item>"; 
     55        } 
    3456         
     57        return new LLReader_Feed($output); 
    3558    } 
    3659} 
Note: See TracChangeset for help on using the changeset viewer.