0

I’ve tried HeaderHelper::setHeader(array('code' => 200)) without success.

  • Can you give a little more context/code examples about what you're trying to do? Craft will do some automatic header response code setting depending on the type of request it is. – Brad Bell Feb 27 '15 at 18:21
  • I was trying to set it as a response to a web hook. 200 for a successful function, or appropriate respone if something went wrong. – James Feb 27 '15 at 19:20
  • This is maybe more appropriate: craftcms.stackexchange.com/questions/478/… – James Mar 6 '15 at 10:04
3

See here for various methods of setting the response code depending on what version of PHP and which PHP module you're running.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.