Changeset 2928:0471a74f04ed for plugins/simpleMenu/_public.php
- Timestamp:
- 01/26/15 13:44:21 (11 years ago)
- Branch:
- default
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/simpleMenu/_public.php
r2912 r2928 31 31 $description = isset($attr['description']) ? trim($attr['description']) : ''; 32 32 33 if (!preg_match('#^(title|span )$#',$description)) {33 if (!preg_match('#^(title|span|both|none)$#',$description)) { 34 34 $description = ''; 35 35 } … … 47 47 global $core, $_ctx; 48 48 49 $descr_type = array(0 => 'span',1 => 'title',2 => 'both',3 => 'none'); 50 49 51 if (!(boolean) $core->blog->settings->system->simpleMenu_active) 50 52 return; … … 58 60 } 59 61 60 $menu = tplSimpleMenu::displayMenu('','','title'); 62 $description = 'title'; 63 if (isset($descr_type[$w->description])) { 64 $description = $descr_type[$w->description]; 65 } 66 $menu = tplSimpleMenu::displayMenu('','',$description); 61 67 if ($menu == '') { 62 68 return; … … 107 113 $title = $span = ''; 108 114 if ($m['descr']) { 109 if ($description == 'title' ) {115 if ($description == 'title' || $description == 'both') { 110 116 $title = ' title="'.html::escapeHTML(__($m['descr'])).'"'; 111 } else { 117 } 118 if ($description == 'span' || $description == 'both') { 112 119 $span = ' <span>'.html::escapeHTML(__($m['descr'])).'</span>'; 113 120 }
Note: See TracChangeset
for help on using the changeset viewer.