* @throws \Exception
*/
public static function getApplication()
{
if (!self::$application) {
throw new \Exception('Failed to start application', 500);
}
return self::$application;
}
////////////$app = JFactory::getApplication(); // comment out after joomla4 migration
echo "<br>DEBUG: inside " . __FILE__ . " line " . __LINE__ . " set mainframe";
/* $mainframe = Factory::getApplication('site'); // attempt after joomla4 migration */
echo "<br>DEBUG: inside " . __FILE__ . " line " . __LINE__ . " SKIPPED mainframe";
echo "<br>DEBUG: inside " . __FILE__ . " line " . __LINE__ . " try adjusted mainframe";
$mainframe = Factory::getApplication(); // attempt after joomla4 migration -- without parsing 'site'
echo "<br>DEBUG: inside " . __FILE__ . " line " . __LINE__ . " set app";
$app = Factory::getApplication(); // attempt after joomla4 migration
echo "<br>DEBUG: inside " . __FILE__ . " line " . __LINE__ . " set prefix";
$prefix = $app->get('dbprefix'); // attempt after joomla4 migration
echo "<br>DEBUG: inside " . __FILE__ . " line " . __LINE__ . " initialize mainframe";
$debugent2 = 0;
$debugent3 = 0;
} // is_test
/// must be before header
include "includes/session.php"; // access joomla login
/*
// test if logged in //
if (isset($my) && $my->username<>"")
{
Exception
|
---|
Exception: Failed to start application at /home/usbf/public_html/libraries/src/Factory.php:158 at Joomla\CMS\Factory::getApplication() (/home/usbf/public_html/apps/includes/session.php:54) at include('/home/usbf/public_html/apps/includes/session.php') (/home/usbf/public_html/apps/entries.php:46) |