I am using xslt.
If my input string is like
<entry colsep="0" rowsep="0" />
<entry colsep="0" rowsep="0">Acid suppressant</entry>
I need to check of the entry tag contains any value. if not, i need to replace it like
<entry colsep="0" rowsep="0">...</entry>
How to check this in XSLT.
Thanks
Pooja
If you want to match an element with no text value, you can simply do this
You can then add your code to copy the element, but add a default value at the same time.
Combining this with the identity transform, gives the following XSLT
When applied to the following XML:
The following is output