Changeset 947 for trunk/rss/util.php

Show
Ignore:
Timestamp:
10/12/05 19:06:40 (3 years ago)
Author:
mbonetti
Message:

Fix for #915. Applied James' enclosure patch. Plugin follows.
(Thank you very much, Jamers!)

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/rss/util.php

    r940 r947  
    241241            } 
    242242 
     243         // enclosure 
     244            if (array_key_exists('enclosure', $item) ) { 
     245            $enclosure = $item['enclosure']; 
     246         } else { 
     247            $enclosure = ""; 
     248         } 
     249 
    243250            // drop items with an url exceeding our column length: we couldn't provide a 
    244251            // valid link back anyway. 
     
    264271 
    265272                $sql = "insert into ".getTable("item") 
    266                 ." (cid, added, title, url, "." description, author, unread, pubdate) " 
     273                ." (cid, added, title, url, enclosure," 
     274            ." description, author, unread, pubdate) " 
    267275                ." values ("."$cid, now(), '$dbtitle', " 
    268                 ." '$url', '".rss_real_escape_string($description)."', '" 
     276                ." '$url', '$enclosure', '" 
     277            .rss_real_escape_string($description)."', '" 
    269278                .rss_real_escape_string($author)."', " 
    270279                ."$mode, $sec)";