XF 2.2 A ton of these errors...

frm

Well-known member
I'm getting a ton of these errors. I was able to get rid of some because some PHP functions were disabled, but these ones still persist. Is it necessary to enable a PHP function here for these?

Code:
Stack trace
#0 internal_data/code_cache/templates/l1/s0/admin/PAGE_CONTAINER.php(219): XF\Template\Templater->handleTemplateError(2, '[E_WARNING] Try...', '/www/wwwroot/of...', 219)
#1 src/XF/Template/Templater.php(1651): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, NULL)
#2 src/XF/Admin/App.php(246): XF\Template\Templater->renderTemplate('PAGE_CONTAINER', Array)
#3 src/XF/App.php(2149): XF\Admin\App->renderPageHtml('

<div class="b...', Array, Object(XF\Mvc\Reply\View), Object(XF\Mvc\Renderer\Html))
#4 src/XF/Admin/App.php(125): XF\App->renderPage('

<div class="b...', Object(XF\Mvc\Reply\View), Object(XF\Mvc\Renderer\Html))
#5 src/XF/Mvc/Dispatcher.php(404): XF\Admin\App->renderPage('

<div class="b...', Object(XF\Mvc\Reply\View), Object(XF\Mvc\Renderer\Html))
#6 src/XF/Mvc/Dispatcher.php(60): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
#7 src/XF/App.php(2351): XF\Mvc\Dispatcher->run()
#8 src/XF.php(517): XF\App->run()
#9 admin.php(13): XF::runApp('XF\\Admin\\App')
#10 {main}
 
You've posted the stack trace but omitted the actual error message.
I don't know which one is the actual error that you use to debug it. So, here are all 3 sections of the output on the latest error accessing the ACP:
Code:
ErrorException: Template error: [E_WARNING] Trying to access array offset on null internal_data/code_cache/templates/l1/s0/admin/PAGE_CONTAINER.php:219
Code:
#0 internal_data/code_cache/templates/l1/s0/admin/PAGE_CONTAINER.php(219): XF\Template\Templater->handleTemplateError(2, '[E_WARNING] Try...', '/www/wwwroot/of...', 219)
#1 src/XF/Template/Templater.php(1651): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, NULL)
#2 src/XF/Admin/App.php(246): XF\Template\Templater->renderTemplate('PAGE_CONTAINER', Array)
#3 src/XF/App.php(2149): XF\Admin\App->renderPageHtml('
    

    
    
        
    
        ...', Array, Object(XF\Mvc\Reply\View), Object(XF\Mvc\Renderer\Html))
#4 src/XF/Admin/App.php(125): XF\App->renderPage('
    

    
    
        
    
        ...', Object(XF\Mvc\Reply\View), Object(XF\Mvc\Renderer\Html))
#5 src/XF/Mvc/Dispatcher.php(404): XF\Admin\App->renderPage('
    

    
    
        
    
        ...', Object(XF\Mvc\Reply\View), Object(XF\Mvc\Renderer\Html))
#6 src/XF/Mvc/Dispatcher.php(60): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
#7 src/XF/App.php(2351): XF\Mvc\Dispatcher->run()
#8 src/XF.php(517): XF\App->run()
#9 admin.php(13): XF::runApp('XF\\Admin\\App')
#10 {main}
Code:
array(4) {
  ["url"] => string(10) "/admin.php"
  ["referrer"] => string(32) "https://offtopic.forum/admin.php"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(0) {
  }
}

This is on 2.2.8 PL 1 if that matters.

Soon to upgrade to 2.3.4, but as for now, I'd hate to have these stack to 26+ pages overnight on a site that's behind basic auth even (don't know what could trigger them with no activity, that I know of).
 
It would also help to know what PHP version you're running.

You said you're running XF 2.2.8 PL1, which has a minimum of PHP 7.0 and a recommended PHP 8.0. If you're running PHP 8.1, 8.2 or 8.3, this is probably what would be the source of your error in this circumstance.
 
It would also help to know what PHP version you're running.

You said you're running XF 2.2.8 PL1, which has a minimum of PHP 7.0 and a recommended PHP 8.0. If you're running PHP 8.1, 8.2 or 8.3, this is probably what would be the source of your error in this circumstance.
Hope this can help.

1735728637322.webp

Was 2.2.8 PL 1 recommended to have 8.0? It's showing me that I have the recommended version.

Perhaps downgrading might help.

Sure does...

1735728802611.webp

I'm wondering if their "recommended version check" is just something as simple as ">= 8" and assumes it'd be compatible with all future upgrades?
 
Yeah it’ll be a compatibility issue with PHP 8.3.
It'd probably be difficult to gauge when a "recommended" version (as seen in ACP) would have breaking changes, but perhaps this could be moved to a XenForo server check as opposed to being hard-coded in XF.

It'd work where if there was ever a compatibility issue, like with what I had, it'd return "You're not running the recommended version. The recommended version is 8.0" or something to that extent in red/yellow by checking XF for the absolute recommended version (in this case, 8.0) against what XF has stored for XF 2.2.8 PL 1 on the XF server-side, which would be updated when bug reports like this come in and can be verified that, perhaps for XF 2.3.5, 8.3.14 remains as the recommended highest 8.3 3rd point release 2-3 years later.

Anyone running XF 2.2.8 PL 2 (or moving forward, 2.3.5/2.4), would get the message back that theirs is not a recommended version of PHP as things progress with PHP changes.

Could also apply to other software like MySQL/etc.
 
Back
Top Bottom