Dear list, I have the following sample: \startbuffer[demo] <html> <body> <div id="First"> <p>This is <span class="special">One of the best</span> a paragraph.</p> <p>This is another paragraph.</p> <p>This is another <span class="special">Two of the best</span> paragraph.</p> <p>This is another <span class="special">Three</span> paragraph.</p> <p>This is another <span class="special">Four of five</span> paragraph.</p> </div> </body> </html> \stopbuffer \startxmlsetups xml:initialize \xmlsetsetup{#1}{html}{xml:gen} \stopxmlsetups \xmlregistersetup{xml:initialize} \startxmlsetups xml:gen \xmlfilter{#1}{/**/div/command(xml:special)} \stopxmlsetups \startxmlsetups xml:special %~ \startitem \cldcontext{string.gsub(lxml.flush([[#1]]), " of the ", "")}\stopitem \stopxmlsetups \starttext \xmlprocessbuffer{main}{demo}{} \stoptext Is there any way to remove " of " and " of the " in the filtered content (xml:special)? Sorry, Lua code is crap for sure. Many thanks for your help, Pablo -- http://www.ousia.tk