// Create a new request object
$requestInstance = ObjectFactory::createObjectByName('HttpRequest');
+ // Remember request instance here
+ $this->setRequestInstance($requestInstance);
+
// Default response is HTTP (HTML page) and type is "Web"
$response = "http";
$responseType = "web";
$responseClass = sprintf("%sResponse", $this->convertToClassName($response));
$responseInstance = ObjectFactory::createObjectByName($responseClass, array($this));
- // Remember both in this application
- $this->setRequestInstance($requestInstance);
+ // Remember response instance here
$this->setResponseInstance($responseInstance);
// Get the parameter from the request
// Get some instances
$tpl = FrameworkConfiguration::getInstance()->readConfig('template_class');
$lang = LanguageSystem::getInstance();
- $io = FileIoHandler::getInstance();
// Get response instance
$responseInstance = ApplicationHelper::getInstance()->getResponseInstance();
// Is the template engine loaded?
- if ((class_exists($tpl)) && (is_object($lang)) && (is_object($io))) {
+ if ((class_exists($tpl)) && (is_object($lang))) {
// Use the template engine for putting out (nicer look) the message
try {
// Get the template instance from our object factory
- $templateInstance = ObjectFactory::createObjectByName($tpl, array(FrameworkConfiguration::getInstance()->readConfig('tpl_base_path'), $lang, $io));
+ $templateInstance = ObjectFactory::createObjectByName($tpl, array(ApplicationHelper::getInstance()));
} catch (FrameworkException $e) {
die(sprintf("[Main:] Could not initialize template engine for reason: <span class=\"exception_reason\">%s</span>",
$e->getMessage()