I am trying to put my template ('qma') right before the message area. I want it to look like this:
http://img408.imageshack.us/i/armoryposition.png/
Right now, I actually have the HTML block of code in the 'newthread' template as I cannot figure out how to get it into that position without doing it that way. I tried searching for the message are with the following code:
Code:
global $vbulletin;
$is_qma_enabled = false;
if($vbulletin->options['qma_onoff'] == 1){
$forums_enabled = explode(',', $vbulletin->options['qma_forumid']);
$is_qma_enabled = in_array($vbulletin->GPC['forumid'], $forums_enabled);
}
if($is_qma_enabled == true){
$show['qma_enabled'] = true;
$newTemplate = vB_Template::create('qma');
$rendered = str_replace( "<", "<", $newTemplate->render() );
$find = "messagearea";
$vbulletin->templatecache['newthread'] = str_replace("messagearea", "", $vbulletin->templatecache['newthread']);
$vbulletin->templatecache['newthread'] = str_replace("' . $ . '", $rendered, $vbulletin->templatecache['newthread']);
}
It works in finding the area that the template should be put (the 'qma' template also has the 'messagearea' part that I am erasing with the above str_replace), but after trying to I get an PHP runtime error:
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in /home/maskedcrusader/includes/class_core.php(4414) : eval()'d code on line 141
It is having a problem with the 'eval' for the template and I cannot seem to find any PHP errors in my code that would cause that error.