Changes

Jump to navigation Jump to search
339 bytes added ,  16:12, 18 February 2015
</pre>
===Content Types===
If a content-type is specified in the request, the content is converted to the following XQuery type. Since {{Version|8.1}}, conversion can be influenced by specifying additional content-type parameters:
{| class="wikitable" width="100%"
|- valign="top"
! Content-Type
! Parameters
! XQuery type
|-
| {{Code|application/json}}
| [[JSON Module|Options|JSON Options]]| {{Code|document-node()}} (conversion is described in the [[JSON Module]])
|-
| {{Code|text/html}}
| [[HTML Module|Options|HTML Options]]| {{Code|document-node()}} (conversion is described in the [[HTML Module]])
|-
| {{Code|text/comma-separated-values}}
| [[CSV Module|Options|CSV Options]]
| {{Code|document-node()}}
|-
| {{Code|text/xml}}, {{Code|application/xml}}
|
| {{Code|document-node()}}
|-
| {{Code|text/*}}
|
| {{Code|xs:string}}
|-
| ''others''
|
| {{Code|xs:base64Binary}}
|-
| {{Code|multipart/*}}
|
| sequence (see next paragraph)
|}
For example, if {{Code|application/json;lax=yes}} is specified as content type, the input will be transformed to JSON, and the lax conversion rules will be applied, as described in the [[JSON Module]]. ===Multipart Types====
The single parts of a multipart message are represented as a sequence,
Bureaucrats, editor, reviewer, Administrators
13,554

edits

Navigation menu