Changeset 1096:3c0cfbe684cc for themes/ductile/_public.php
- Timestamp:
- 01/19/13 12:20:15 (13 years ago)
- Branch:
- default
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
themes/ductile/_public.php
r1081 r1096 23 23 $core->tpl->addValue('ductileNbEntryPerPage',array('tplDuctileTheme','ductileNbEntryPerPage')); 24 24 $core->tpl->addValue('ductileLogoSrc',array('tplDuctileTheme','ductileLogoSrc')); 25 $core->tpl->addBlock('IfPreviewIsNotMandatory',array('tplDuctileTheme','IfPreviewIsNotMandatory')); 25 26 26 27 class tplDuctileTheme … … 175 176 176 177 return $img_url; 178 } 179 180 public static function IfPreviewIsNotMandatory($attr,$content) 181 { 182 $s = $GLOBALS['core']->blog->settings->themes->get($GLOBALS['core']->blog->settings->system->theme.'_style'); 183 if ($s !== null) { 184 $s = @unserialize($s); 185 if (is_array($s)) { 186 if (isset($s['preview_not_mandatory'])) { 187 if ($s['preview_not_mandatory']) { 188 return $content; 189 } 190 } 191 } 192 } 193 return ''; 177 194 } 178 195
Note: See TracChangeset
for help on using the changeset viewer.