xdmp:uri-content-type( $uri as xs:string ) as xs:string
Returns the content type of the given URI as matched in the mimetypes configuration. xdmp:content-type continues to work too.
Parameters | |
---|---|
uri | The document URI. |
xdmp:uri-content-type("example.txt") => text/plain
xdmp:uri-content-type("example.xml") => application/xml
xdmp:uri-content-type("example.doc") => application/msword
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.