web.status_code

web.status_code

web.status_code

Function

Set HTTP response status code.

Syntax

Parameters

ParametersTypeRequiredDefault valueDescription
codeIntYesNoneHTTP status code, valid range 100 to 999.

Return value

TypeDescription
BoolReturns true if the setting is successful.

Example

Notes

  • Throw an error when the status code is out of range.