mirror of
https://github.com/e107inc/e107.git
synced 2025-08-30 01:30:32 +02:00
News Grid template simplified. Template/Layout combination consolidated into 'layout' only.
This commit is contained in:
@@ -60,14 +60,14 @@ if(false === $cached)
|
||||
}
|
||||
else // New in v2.1.5
|
||||
{
|
||||
$tmpl = !empty($parms['template']) ? $parms['template'] : 'default';
|
||||
$tmpl = !empty($parms['layout']) ? $parms['layout'] : 'col-md-4';
|
||||
$template = e107::getTemplate('news', 'news_grid', $tmpl);
|
||||
$parms['tmpl'] = 'news_grid';
|
||||
$parms['tmpl_key'] = $tmpl;
|
||||
|
||||
}
|
||||
|
||||
$gridSize = vartrue($parms['layout'],'col-md-4');
|
||||
// $gridSize = vartrue($parms['layout'],'col-md-4');
|
||||
|
||||
$parmSrch = array(
|
||||
'{NEWSGRID}',
|
||||
@@ -76,12 +76,12 @@ if(false === $cached)
|
||||
);
|
||||
|
||||
$parmReplace = array(
|
||||
$gridSize,
|
||||
vartrue($parms['titleLimit'], 0),
|
||||
vartrue($parms['summaryLimit'], 0)
|
||||
// $gridSize,
|
||||
// vartrue($parms['titleLimit'], 0),
|
||||
// vartrue($parms['summaryLimit'], 0)
|
||||
);
|
||||
|
||||
$template = str_replace($parmSrch , $parmReplace, $template);
|
||||
$template = str_replace($parmSrch , '', $template); // clean up deprecated elements.
|
||||
|
||||
$render = (empty($parms['caption'])) ? false: true;
|
||||
|
||||
|
Reference in New Issue
Block a user