mirror of
https://github.com/e107inc/e107.git
synced 2025-08-30 09:39:55 +02:00
Additional information passed to news_style function (theme function) - current action and parameters (as set in news class and news view)
This commit is contained in:
@@ -507,7 +507,8 @@ class news {
|
||||
{
|
||||
global $NEWSSTYLE, $NEWSLISTSTYLE;
|
||||
|
||||
if ($override_newsitem = e107::getSingleton('override', true)->override_check('render_newsitem')) {
|
||||
if ($override_newsitem = e107::getSingleton('override', true)->override_check('render_newsitem'))
|
||||
{
|
||||
$result = call_user_func($override_newsitem, $news, $mode, $n_restrict, $NEWS_TEMPLATE, $param);
|
||||
if ($result == 'return')
|
||||
{
|
||||
@@ -587,8 +588,10 @@ class news {
|
||||
if ($NEWS_TEMPLATE) {
|
||||
$NEWS_PARSE = $NEWS_TEMPLATE;
|
||||
} else {
|
||||
if (function_exists("news_style")) {
|
||||
$NEWS_PARSE = news_style($news);
|
||||
if (function_exists("news_style"))
|
||||
{
|
||||
$action = varset($param['current_action'], 'default');
|
||||
$NEWS_PARSE = news_style($news, $action, $param);
|
||||
} else {
|
||||
$NEWS_PARSE = $NEWSSTYLE;
|
||||
}
|
||||
|
Reference in New Issue
Block a user