Dotclear


Ignore:
Timestamp:
09/04/13 14:57:03 (12 years ago)
Author:
Dsls
Branch:
default
Message:

Added dcAdminCombos utility class, lots of combos available from everywhere now. Closes #1599

File:
1 edited

Legend:

Unmodified
Added
Removed
  • admin/index.php

    r1718 r1719  
    364364     { 
    365365          # Getting categories 
    366           $categories_combo = array(__('(No cat)') => ''); 
    367           try { 
    368                $categories = $core->blog->getCategories(array('post_type'=>'post')); 
    369                if (!$categories->isEmpty()) { 
    370                     while ($categories->fetch()) { 
    371                          $catparents_combo[] = $categories_combo[] = new formSelectOption( 
    372                               str_repeat('  ',$categories->level-1).($categories->level-1 == 0 ? '' : '• ').html::escapeHTML($categories->cat_title), 
    373                               $categories->cat_id 
    374                          ); 
    375                     } 
    376                } 
    377           } catch (Exception $e) { } 
     366          $categories_combo = dcAdminCombos::getCategoriesCombo( 
     367               $core->blog->getCategories(array('post_type'=>'post')) 
     368          ); 
    378369      
    379370          echo 
Note: See TracChangeset for help on using the changeset viewer.

Sites map