Hugilore111
Member
Help me , where I'm doing wrong!
In MyAddOns_Enter_ViewPublic_EnterHome_Index
parsing the template
Finally my fault
Fatal error: Can not use object of type XenForo_BbCode_TextWrapper as array in
PHP:
$viewParams = array(
'enter => $resDbConnect->getValue(//receive data array ),
.........
);
return $this->responseView('MyAddOns_Enter_ViewPublic_EnterHome_Index','enter_my_home' , $viewParams,);
PHP:
class MyAddOns_Enter_ViewPublic_EnterHome_Index extends XenForo_ViewPublic_Base
{
public function renderHtml()
{
$this->parseBBCodeInEnter();
}
private function parseBBCodeEnter()
{
$bbCodeOptions = array(
'states' => array(
'viewAttachments' => true
)
);
$bbCodeParser = new XenForo_BbCode_Parser(XenForo_BbCode_Formatter_Base::create('Base', array('view' => $this)));
$this->_params['enter']['messageHtml'] = XenForo_ViewPublic_Helper_Message::getBbCodeWrapper($this->_params['enter'], $bbCodeParser, $bbCodeOptions);
}
parsing the template
PHP:
<xen:foreach loop="$entryy" key="$kk" value="$en" >
{xen:raw $en.enter.messageHtml}
</xen:foreach>
Finally my fault
Fatal error: Can not use object of type XenForo_BbCode_TextWrapper as array in