Citrix Systems Network Router 9.2 User Manual
138
Citrix NetScaler Policy Configuration and Reference Guide
text.XPATH_JSON(xpathex)
Operate on a JSON file and return a node-set
or a string. Node-sets are converted to
corresponding strings by using the standard
XPath string conversion routine.
or a string. Node-sets are converted to
corresponding strings by using the standard
XPath string conversion routine.
For example, consider the following JSON
file:
file:
{ "Book":{ "creator":{ "person":{
"name":'<name>' } }, "title":'<title>' } }
"name":'<name>' } }, "title":'<title>' } }
The following expression selects all the nodes
that are enclosed by “/Book" (a node-set) in
the first 1000 bytes of the body of the JSON
file and returns the corresponding string
value, which is "<name><title>":
that are enclosed by “/Book" (a node-set) in
the first 1000 bytes of the body of the JSON
file and returns the corresponding string
value, which is "<name><title>":
HTTP.REQ.BODY(1000).XPATH_
JSON(xp%/Book%)
JSON(xp%/Book%)
Parameters:
xpathex - XPath expression
text.XPATH_JSON_WITH_
MARKUP(xpathex)
MARKUP(xpathex)
Operate on an XML file and return a string
that contains the entire portion of the
document for the result node, including
markup such as including the enclosing
element tags.
that contains the entire portion of the
document for the result node, including
markup such as including the enclosing
element tags.
For example, consider the following JSON
file:
file:
{"Book":{ "creator":{ "person":{
"name":'<name>' } }, "title":'<title>' } }
"name":'<name>' } }, "title":'<title>' } }
The following expression operates on the
JSON file and selects all the nodes that are
enclosed by “/Book/creator" in the first 1000
bytes of the body, which is “creator:{ person:{
name:'<name>' } }.”
JSON file and selects all the nodes that are
enclosed by “/Book/creator" in the first 1000
bytes of the body, which is “creator:{ person:{
name:'<name>' } }.”
HTTP.REQ.BODY(1000).XPATH_JSON_
WITH_MARKUP(xp%/Book/creator%)
WITH_MARKUP(xp%/Book/creator%)
The portion of the JSON body that is selected
by the expression is marked for further
processing.
by the expression is marked for further
processing.
Parameters:
xpathex - XPath expression
XPath Prefix
Description