Is it possible to detect the presence of a (xml) tag using XSLT? -
I think to test the presence of a tag and create a new node according to the result. This input is XML: & lt; Root & gt; & Lt; Tag1 & gt; NS & lt; / Tag1 & gt; & Lt; Tag2 id = "8" & gt; NS & lt; / Tag2 & gt; & Lt; Test & gt; & Lt; Other_tag> Text & lt; / Other_tag> & Lt; Main & gt; Y & lt; / Home & gt; & Lt; / Test & gt; & Lt; Test & gt; & Lt; Other_tag> Text & lt; / Other_tag> & Lt; / Test & gt; & Lt; / Root & gt; and the required output is XML: & lt; Root & gt; & Lt; Tag1 & gt; NS & lt; / Tag1 & gt; & Lt; Tag2 id = "8" & gt; NS & lt; / Tag2 & gt; & Lt; Test & gt; & Lt; Other_tag> Text & lt; / Other_tag> & Lt; Main_Tag & gt; Current & lt; / Main_Tag & gt; & Lt; / Test & gt; & Lt; Test & gt; & Lt; Other_tag> Text & lt; / Other...