Changes

Jump to navigation Jump to search
844 bytes added ,  16:49, 21 October 2021
no edit summary
<syntaxhighlight lang="xquery">
$nodes ! /
</syntaxhighlight>
|}
 
==util:strip-namespaces==
 
{{Mark|Introduced with Version 10.0:}}
 
{| width='100%'
|-
| width='120' | '''Signatures'''
|{{Func|util:strip-namespaces|$node as node()|node()}}<br/>{{Func|util:strip-namespaces|$node as node(), $prefixes as xs:string*|node()}}<br/>
|-
| '''Summary'''
|Removes namespaces with the specified <code>$prefixes</code> from the supplied <code>$node</code>. An empty string can be supplied to remove the default namespace. If no prefixes are specified, all namespaces will be removed.
|-
| '''Examples'''
| Remove all namespaces from an element and its descendants:
<syntaxhighlight lang="xquery">
util:strip-namespaces(<xml xmlns='x' prefix:name='value'><prefix:child/></xml>)
 
(: yields :)
<xml name='value'><child/></xml>
</syntaxhighlight>
|}
=Changelog=
 
;Version 10.0
* Added: [[#util:strip-namespaces|util:strip-namespaces]]
;Version 9.5
Bureaucrats, editor, reviewer, Administrators
13,550

edits

Navigation menu