How to change HTTP response code?

#1
[eluser]Hartimer[/eluser]
Is it possible to change Codeigniter's HTTP response code?

Since i have a controller that outputs json, that would be nice so i could "alert" the client about "exceptions".
Obviously this could be done through the json response itself, but i think it would be cleaner to do it by http response code..

#2
[eluser]WanWizard[/eluser]
See the manual, in the output class:
Code:
$this->output->set_status_header(code, 'text');

#3
[eluser]Hartimer[/eluser]
I've looked all over the place, including the search on this forums.... maybe i used the wrong search terms...

Anyway, thank you alot


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.