[eluser]Ñuño Martínez[/eluser]
I wrote a controller to send the CSS file. In short, it's something like this:
Code:
class styles extends CI_Controller {
public function _remap ($Metodo)
{
$this->load->helper ('file');
if ($Metodo == 'estilo.css' or $Metodo == 'estilo')
echo read_file (DIR_TEMPLATE.'estilo.css');
elseif ($Metodo == 'form.css' or $Metodo == 'form')
echo read_file (DIR_TEMPLATE.'form.css');
else
show_404 ($Metodo);
}
};
It works. I mean it returns the correct CSS code. The problem is that it includes 'Content-Type: "text/html; charset=..."' in the header so the browser doesn't recognizes it as CSS code, so it doesn't applies the styles to the document. I've tested it in Firefox and Midori (Webkit).
Is it possible to avoid the "Content-Type" header?