/** * Indica el tipo de Respuesta dada por el controlador * buscando el view con esa extension. * ej. View::response('xml'); * buscara: views/controller/action.xml.phtml * * @param string $response * @param string $template Opcional nombre del template sin .phtml */ public static function response($response, $template = FALSE) { self::$_response = $response; // verifica si se indico template if ($template !== FALSE) { self::$_template = $template; } }
/** * Indica el tipo de Respuesta dada por el controlador * buscando el view con esa extension. * ej. View::response('xml'); * buscara: views/controller/action.xml.phtml * * @param string $response * @param string $template Opcional nombre del template sin .phtml */ public static function response($response, $template = FALSE) { if ($response == 'view') { //se mantiene pero ya esta deprecated self::$_template = NULL; } else { self::$_response = $response; } // verifica si se indico template if ($template !== FALSE) { self::$_template = $template; } }