Ejemplo n.º 1
0
 /**
  * And more BC
  * Checks and does some addtional logic if registered module is of type legacy
  * @param eRequest $request
  * @return void
  */
 public function checkLegacy(eRequest $request)
 {
     $module = $request->getModule();
     // forward from controller to a legacy module - bad stuff
     if (!$request->isDispatched() && $this->getConfigValue($module, 'legacy')) {
         eFront::isLegacy($this->getConfigValue($module, 'legacy'));
         $url = $this->assemble($request->getRoute(), $request->getRequestParams());
         $request->setRequestInfo($url)->setPathInfo(null)->setRoute(null);
         $_GET = $request->getRequestParams();
         $_SERVER['QUERY_STRING'] = http_build_query($request->getRequestParams(), null, '&');
         // Infinite loop impossible, as dispatcher will break because of the registered legacy path
         $this->route($request);
     }
 }