ltm rule command HTTP statusΒΆ

iRule(1)						BIG-IP TMSH Manual						  iRule(1)

HTTP::status
       Returns the response status code.

SYNOPSIS
       HTTP::status

DESCRIPTION
       Returns the response status code as defined in RFC2616

       Syntax

       HTTP::status

	    * Returns the response status code as defined in RFC2616

RETURN VALUE
       Returns the response status code.

VALID DURING
       HTTP_RESPONSE, HTTP_RESPONSE_DATA, HTTP_PROXY_RESPONSE, MR_INGRESS

EXAMPLES
	when HTTP_RESPONSE {
	  if { [HTTP::status] == 404 } {
	    HTTP::redirect "http://www.example.com/not_found.html"
	 }
	}

HINTS
SEE ALSO
CHANGE LOG
       @BIGIP-9.0.0 --First introduced the command.

BIG-IP							    2022-04-12							  iRule(1)