Changeset 3157 for plugins/categoriesMode/_widgets.php
- Timestamp:
- 08/02/13 18:00:31 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/categoriesMode/_widgets.php
r3067 r3157 23 23 if (!$core->blog->settings->categoriesmode->categoriesmode_active) return; 24 24 25 if ($w->homeonly && $core->url->type != 'default') { 25 if (($w->homeonly == 1 && $core->url->type != 'default') || 26 ($w->homeonly == 2 && $core->url->type == 'default')) { 26 27 return; 27 28 } 28 29 29 $res = 30 '<div class="categories">'. 30 $res = ($w->content_only ? '' : '<div class="categories'.($w->class ? ' '.html::escapeHTML($w->class) : '').'">'). 31 31 ($w->title ? '<h2>'.html::escapeHTML($w->title).'</h2>' : ''). 32 32 '<ul>'; … … 37 37 38 38 $res .= '</ul>'. 39 '</div>';39 ($w->content_only ? '' : '</div>'); 40 40 41 41 return $res; … … 47 47 48 48 $w->CategoriesPage->setting('title',__('Title:'),__('Categories page'),'text'); 49 $w->CategoriesPage->setting('homeonly',__('Home page only'),0,'check'); 49 $w->CategoriesPage->setting('homeonly',__('Display on:'),0,'combo', 50 array( 51 __('All pages') => 0, 52 __('Home page only') => 1, 53 __('Except on home page') => 2 54 ) 55 ); 56 $w->CategoriesPage->setting('content_only',__('Content only'),0,'check'); 57 $w->CategoriesPage->setting('class',__('CSS class:'),''); 50 58 } 51 59 }
Note: See TracChangeset
for help on using the changeset viewer.