1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-05 14:17:49 +02:00

Menu renders 'start' and 'end' templates now;

Comment about usage of SETIMAGE sc in menu template;
SETIMAGE: default - reset to default (TODO - site prefs)
This commit is contained in:
SecretR
2013-10-18 11:03:01 +03:00
parent c49756982f
commit 48f41709c8
2 changed files with 8 additions and 0 deletions

View File

@@ -3,6 +3,13 @@
function setimage_shortcode($parm, $mode='')
{
### Reset to defaults TODO site prefs
if(isset($parm['default']))
{
$parm['w'] = 100;
$parm['h'] = 0;
$parm['crop'] = 0;
}
e107::getParser()->thumbWidth = vartrue($parm['w'],100);
e107::getParser()->thumbHeight = vartrue($parm['h'],0);
e107::getParser()->thumbCrop = vartrue($parm['crop'],0);

View File

@@ -12,6 +12,7 @@
$MENU_TEMPLATE['button']['body'] = '{CMENUBODY}{CPAGEBUTTON}';
$MENU_TEMPLATE['button']['end'] = '</div>';
### Additional control over image thumbnailing is possible via SETIMAGE e.g. {SETIMAGE: w=200&h=150&crop=1}
$MENU_TEMPLATE['buttom-image']['start'] = '<div class="cpage-menu">';
$MENU_TEMPLATE['buttom-image']['body'] = '{CMENUIMAGE}{CPAGEBUTTON}';
$MENU_TEMPLATE['buttom-image']['end'] = '</div>';