mirror of
https://github.com/e107inc/e107.git
synced 2025-08-05 14:17:49 +02:00
Check for installed poll plugin before retrieving poll info on topic view
This commit is contained in:
@@ -145,6 +145,8 @@ if ($thread->message)
|
|||||||
|
|
||||||
//if (isset($thread->threadInfo['thread_options']['poll'])) //XXX Currently Failing - misconfigured thread-options.
|
//if (isset($thread->threadInfo['thread_options']['poll'])) //XXX Currently Failing - misconfigured thread-options.
|
||||||
//{
|
//{
|
||||||
|
if(e107::isInstalled('poll'))
|
||||||
|
{
|
||||||
$_qry = 'SELECT * FROM `#polls` WHERE `poll_datestamp` = ' . $thread->threadId;
|
$_qry = 'SELECT * FROM `#polls` WHERE `poll_datestamp` = ' . $thread->threadId;
|
||||||
if($sql->gen($_qry))
|
if($sql->gen($_qry))
|
||||||
{
|
{
|
||||||
@@ -155,6 +157,7 @@ if ($thread->message)
|
|||||||
$poll = new poll;
|
$poll = new poll;
|
||||||
$pollstr = "<div class='spacer'>" . $poll->render_poll($_qry, 'forum', 'query', true) . '</div>';
|
$pollstr = "<div class='spacer'>" . $poll->render_poll($_qry, 'forum', 'query', true) . '</div>';
|
||||||
}
|
}
|
||||||
|
}
|
||||||
//}
|
//}
|
||||||
//Load forum templates
|
//Load forum templates
|
||||||
// FIXME - new template paths!
|
// FIXME - new template paths!
|
||||||
|
Reference in New Issue
Block a user