4
Thanks for the answers.
I solved it using this code.
For now it works well. I'll keep doing tests.
include dirname(__FILE__) . DIRECTORY_SEPARATOR . '../../mainfile.php';
if (isset($GLOBALS['xoopsUser']) && is_object($GLOBALS['xoopsUser'])) { ?>
Any content
}else {redirect_header(XOOPS_URL . "/user.php");} include(XOOPS_ROOT_PATH."/footer.php"); ?>
Thank you and Happy New Year