It’s pretty easy to set the status code for a WebRequest being handled in HandleSpecialURL…
Request.Status = 403
Request.Print("Delete isn't allowed.")
… but how do you alter the very first line of the response header text because at the moment it always just wraps the status code like this…
HTTP/1.1 403 OK
… whereas I would like it to be …
HTTP/1.1 403 Forbidden
I have no problem setting the response body and any other headers, that’s all exposed just fine, but that very first line in the response header always seems to end in “OK”.
Is there a way to change that “OK” to “Forbidden” or “Not Found” or whatever text would make more sense as status text to match the code?