Dotclear

Changeset 2034


Ignore:
Timestamp:
01/29/10 07:10:11 (13 years ago)
Author:
JcDenis
Message:

zoneclearFeedServer 0.3.1:

  • Fixed bug with getURL on classic post
Location:
plugins/zoneclearFeedServer
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • plugins/zoneclearFeedServer/_define.php

    r2032 r2034  
    1717     /* Description*/         "Mix your blog with a feeds planet", 
    1818     /* Author */             "JC Denis, BG", 
    19      /* Version */            '0.3', 
     19     /* Version */            '0.3.1', 
    2020     /* Permissions */        'admin' 
    2121); 
    22      /* date */          #20100127 
     22     /* date */          #20100129 
    2323?> 
  • plugins/zoneclearFeedServer/_public.php

    r2032 r2034  
    3434          $zc->checkFeedsUpdate(); 
    3535          return; 
    36  
    3736     } 
    3837} 
    3938 
    40 class zoneclearFeedServerPosts extends rsExtPostPublic 
     39class zoneclearFeedServerPosts extends rsExtPost 
    4140{ 
    4241     public static function zcFeed(&$rs,$info) 
     
    4746     public static function zcFeedBrother($type,$args) 
    4847     { 
    49           $func =  isset($GLOBALS['beforeZcFeedRsExt'][$type]) ? 
    50                $GLOBALS['beforeZcFeedRsExt'][$type] : 
    51                array('rsExtPostPublic',$type); 
    52  
     48          if (isset($GLOBALS['beforeZcFeedRsExt'][$type])) { 
     49               $func = $GLOBALS['beforeZcFeedRsExt'][$type]; 
     50          } 
     51          elseif (is_callable('rsExtPostPublic',$type)) { 
     52               $func = array('rsExtPostPublic',$type); 
     53          } 
     54          else { 
     55               $func = array('rsExtPost',$type); 
     56          } 
    5357          return call_user_func_array($func,$args); 
    5458     } 
    55       
     59 
    5660     public static function getAuthorLink(&$rs) 
    5761     { 
     
    6064          $sitename = $rs->zcFeed('sitename'); 
    6165 
    62           if ($author && $sitename) 
    63           { 
    64                return $author.' (<a href="'.$site.'">'.$sitename.'</a>)'; 
    65           } 
    66           else 
    67           { 
    68                return self::zcFeedBrother('getAuthorLink',array(&$rs)); 
    69           } 
     66          return ($author && $sitename) ? 
     67               $author.' (<a href="'.$site.'">'.$sitename.'</a>)' : 
     68               self::zcFeedBrother('getAuthorLink',array(&$rs)); 
    7069     } 
    71       
     70 
    7271     public static function getAuthorCN(&$rs) 
    7372     { 
    7473          $author = $rs->zcFeed('author'); 
    75           return $author ? $author : self::zcFeedBrother('getAuthorCN',array(&$rs)); 
     74          return $author ?  
     75               $author :  
     76               self::zcFeedBrother('getAuthorCN',array(&$rs)); 
    7677     } 
    77       
     78 
    7879     public static function getURL(&$rs) 
    7980     { 
    80           $url = zoneclearFeedServer::absoluteURL($rs->zcFeed('site'),$rs->zcFeed('url')); 
    81           return $url ? $url : self::zcFeedBrother('getURL',array(&$rs)); 
     81          $url = $rs->zcFeed('url'); 
     82 
     83          return $url ?  
     84               zoneclearFeedServer::absoluteURL($rs->zcFeed('site'),$url) :  
     85               self::zcFeedBrother('getURL',array(&$rs)); 
    8286     } 
    83       
     87 
    8488     public static function getContent(&$rs,$absolute_urls=false) 
    8589     { 
     
    8791          $sitename = $rs->zcFeed('sitename'); 
    8892          $content = self::zcFeedBrother('getContent',array(&$rs,$absolute_urls)); 
    89            
    90           if ($url && $sitename && $rs->post_type == 'post') 
    91           { 
     93 
     94          if ($url && $sitename && $rs->post_type == 'post') { 
    9295               return $content . 
    9396               '<p class="zonclear-original"><em>'. 
  • plugins/zoneclearFeedServer/release.txt

    r2032 r2034  
    33 * Add feed rating (with rateIt ?) 
    44 * Add public page of feed desription 
     5 
     60.3.1 20100128 
     7 * Fixed bug with getURL on classic post 
    58 
    690.3 20100127 
Note: See TracChangeset for help on using the changeset viewer.

Sites map