public function editAction() { switch ($this->request["METHOD"]) { case 'GET': $xml = new Form($this->request[2]); break; case 'POST': $xml = new Form($this->request['modulo']); break; } $template = "_xml" . '/edit.html.twig'; $this->values['xml'] = $xml->getXml(); switch ($this->request['accion']) { case 'Guardar': //GUARDAR DATOS $template = "_xml" . '/index.html.twig'; return array('template' => $template, 'values' => $this->values); break; } return array('template' => $template, 'values' => $this->values); }