Re: [basex-talk] Way to escape XML?

2019-03-24 Thread Andreas Mixich
Am 24.03.2019 um 06:47 schrieb Liam R. E. Quin: > Note that if you don’t have the XML output method, strings are output > without escaping, so you can’t see that it has worked. Interesting, indeed. I wonder whether it wouldn't make sense, to have BaseX provide escape()/unescape() shortcut

Re: [basex-talk] Way to escape XML?

2019-03-24 Thread Liam R. E. Quin
On Sun, 2019-03-24 at 04:22 +0100, Andreas Mixich wrote: > let $xml as element() := Hello World > return serialize($xml, map{"method":"entity-escaped-string"} > > would result in > > xmlHello World/xml One way, declare function local:escapexml($input as item()*) as xs:string? {