0
$status_header = 'HTTP/1.1 ' . $status . ' ' . getStatusCodeMessage($status);
header($status_header);
header('Content-type: application/json; charset=utf-8');

I updated OS X 10.8 to 10.9, php 5.3.26 to 5.4.17. At php 5.3.26, No error!!! but error occur at php 5.4.17.

When return json to iOS, 
Warning: Cannot modify header information - headers already sent by (output started at 
Su Myat Mon
  • 31
  • 1
  • 5
  • PHP's config has probably been changed in the upgrade, more specifically output buffering has probably been turned off. Without output buffering you MUST do everything that sends headers before anything that sends output. – GordonM Nov 03 '13 at 07:58
  • http://stackoverflow.com/questions/8028957/headers-already-sent-by-php – Krish R Nov 03 '13 at 08:16

0 Answers0