mirror of
https://github.com/e107inc/e107.git
synced 2025-07-29 02:40:25 +02:00
Third-party compatibility for forum shortcode vars.
This commit is contained in:
@@ -1366,7 +1366,8 @@ class e_shortcode
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Alias of setParserVars - Preferred use by Plugins.
|
* Alias of setParserVars - Preferred use by Plugins.
|
||||||
|
* Sets the value of $sc->var
|
||||||
*/
|
*/
|
||||||
public function setVars($eVars) // Alias of setParserVars();
|
public function setVars($eVars) // Alias of setParserVars();
|
||||||
{
|
{
|
||||||
|
@@ -474,6 +474,7 @@ foreach ($postList as $postInfo)
|
|||||||
$alt = !$alt;
|
$alt = !$alt;
|
||||||
|
|
||||||
$sc->setScVar('postInfo', $postInfo);
|
$sc->setScVar('postInfo', $postInfo);
|
||||||
|
$sc->setVars($postInfo); // compatibility
|
||||||
|
|
||||||
if($postInfo['post_status'])
|
if($postInfo['post_status'])
|
||||||
{
|
{
|
||||||
@@ -493,6 +494,7 @@ foreach ($postList as $postInfo)
|
|||||||
{
|
{
|
||||||
$postInfo['thread_start'] = true;
|
$postInfo['thread_start'] = true;
|
||||||
$sc->setScVar('postInfo', $postInfo);
|
$sc->setScVar('postInfo', $postInfo);
|
||||||
|
$sc->setVars($postInfo); // compatibility
|
||||||
$sc->wrapper('forum_viewtopic/thread');
|
$sc->wrapper('forum_viewtopic/thread');
|
||||||
// $forum_shortcodes = e107::getScBatch('view', 'forum')->setScVar('postInfo', $postInfo)->wrapper('forum/viewtopic');
|
// $forum_shortcodes = e107::getScBatch('view', 'forum')->setScVar('postInfo', $postInfo)->wrapper('forum/viewtopic');
|
||||||
$forthr = $tp->parseTemplate($FORUMTHREADSTYLE, true, vartrue($sc)) . "\n";
|
$forthr = $tp->parseTemplate($FORUMTHREADSTYLE, true, vartrue($sc)) . "\n";
|
||||||
|
Reference in New Issue
Block a user