Hugo Santos
Active member
Hi to all,
need some help with this error, after upgrade to xf 2.0.
I've some pages nodes configured and working without any problem, and now:
My implementation is:
On $XENFOROBASEDIR/library/XenForo/Pages
The page is:
https://www.miuiportugal.pt/roms/phps/static/roms-v7.html
And is not loading any scripts.
Just try to make a test to create other page with same config and:
Obs: all vars $SOMEVAR is to hide real info
Thanks for the help, i'm realy stuck on this, supposedly, should work as before, right?
Thanks for the help and best regards
need some help with this error, after upgrade to xf 2.0.
I've some pages nodes configured and working without any problem, and now:
Code:
ErrorException: [E_WARNING] call_user_func_array() expects parameter 1 to be a valid callback, class 'XenForo_Pages_RomV7' not found in src/XF/Pub/Controller/Page.php at line 58
XF::handlePhpError()
call_user_func_array() in src/XF/Pub/Controller/Page.php at line 58
XF\Pub\Controller\Page->actionIndex() in src/XF/Mvc/Dispatcher.php at line 249
XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 89
XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 41
XF\Mvc\Dispatcher->run() in src/XF/App.php at line 1880
XF\App->run() in src/XF.php at line 328
XF::runApp() in index.php at line 13
Code:
ErrorException: [E_WARNING] call_user_func_array() expects parameter 1 to be a valid callback, class 'XenForo_Pages_RomV7' not found src/XF/Pub/Controller/Page.php:58
#0 [internal function]: XF::handlePhpError(2, 'call_user_func_...', '/home/miuiportu...', 58, Array)
#1 src/XF/Pub/Controller/Page.php(58): call_user_func_array(Array, Array)
#2 src/XF/Mvc/Dispatcher.php(249): XF\Pub\Controller\Page->actionIndex(Object(XF\Mvc\ParameterBag))
#3 src/XF/Mvc/Dispatcher.php(89): XF\Mvc\Dispatcher->dispatchClass('XF:Page', 'index', 'html', Object(XF\Mvc\ParameterBag), 'forums', Object(XF\Pub\Controller\Page), NULL)
#4 src/XF/Mvc/Dispatcher.php(41): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch))
#5 src/XF/App.php(1880): XF\Mvc\Dispatcher->run()
#6 src/XF.php(328): XF\App->run()
#7 index.php(13): XF::runApp('XF\\Pub\\App')
#8 {main}
Code:
array(4) {
["url"] => string(16) "/forum/pages/V7/"
["referrer"] => string(45) "https://www.miuiportugal.pt/forum/pages/Roms/"
["_GET"] => array(0) {
}
["_POST"] => array(0) {
}
}
My implementation is:
On $XENFOROBASEDIR/library/XenForo/Pages
Code:
<?php
class XenForo_Pages_Romv7
{
public static function includeFile(XenForo_ControllerPublic_Abstract $controller, XenForo_ControllerResponse_Abstract &$respons
e)
{
ob_start();
require('$MYLOCALDIR/roms/phps/static/roms-v7.html');
$RomV7 = ob_get_contents();
ob_end_clean();
$params = array(
'RomV7' => $RomV7
);
$response->params = array_merge(
$response->params,
$params
);
}
}
The page is:
https://www.miuiportugal.pt/roms/phps/static/roms-v7.html
And is not loading any scripts.
Just try to make a test to create other page with same config and:
Obs: all vars $SOMEVAR is to hide real info
Thanks for the help, i'm realy stuck on this, supposedly, should work as before, right?
Thanks for the help and best regards