frontend\Init::initialize PHP Method

initialize() public method

public initialize ( string $type )
$type string The type of init to load, possible values are: frontend, frontend_ajax, frontend_js.
    public function initialize($type)
    {
        parent::initialize($type);
        \SpoonFilter::disableMagicQuotes();
    }

Usage Example

Example #1
0
 /**
  * @param string $app The name of the application to load (ex. frontend_ajax)
  *
  * @return string The name of the application class we need to instantiate.
  */
 protected function initializeFrontend($app)
 {
     $init = new FrontendInit($this->container->get('kernel'));
     $init->initialize($app);
     return $app === 'FrontendAjax' ? 'Frontend\\Core\\Engine\\Ajax' : 'Frontend\\Core\\Engine\\Frontend';
 }