Dotclear


Ignore:
Timestamp:
07/31/12 13:52:11 (13 years ago)
Author:
Dsls <dsls@…>
Branch:
sexy
Message:

sexy step 2 : no more cats.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • inc/public/lib.urlhandlers.php

    r848 r851  
    245245               $_ctx->cur_lang = $args; 
    246246               self::home(null); 
    247           } 
    248      } 
    249       
    250      public static function category($args) 
    251      { 
    252           $_ctx =& $GLOBALS['_ctx']; 
    253           $core =& $GLOBALS['core']; 
    254            
    255           $n = self::getPageNumber($args); 
    256            
    257           if ($args == '' && !$n) { 
    258                # No category was specified. 
    259                self::p404(); 
    260           } 
    261           else 
    262           { 
    263                $params = new ArrayObject(array( 
    264                     'cat_url' => $args, 
    265                     'post_type' => 'post')); 
    266                 
    267                $core->callBehavior('publicCategoryBeforeGetCategories',$params,$args); 
    268                 
    269                $_ctx->categories = $core->blog->getCategories($params); 
    270                 
    271                if ($_ctx->categories->isEmpty()) { 
    272                     # The specified category does no exist. 
    273                     self::p404(); 
    274                } 
    275                else 
    276                { 
    277                     if ($n) { 
    278                          $GLOBALS['_page_number'] = $n; 
    279                     } 
    280                     self::serveDocument('category.html'); 
    281                } 
    282247          } 
    283248     } 
Note: See TracChangeset for help on using the changeset viewer.

Sites map