[eluser]Unknown[/eluser]
In all of my responses, there is a newline before the actual content. For example, let's say I have the following controller:
Code:
class Api extends CI_Controller {
function upvote() {
$slug = $this->input->get("slug");
header("Content-Type: application/json");
echo $slug;
}
}
When I hit this resource, there's a newline inserted in the response. Like so:
Code:
1
2 this-is-the-slug
Is this a bug in the framework or am I doing something wrong?
Thanks!