I have a transformation that outputs HTML. In order to avoid self-closing tags that could break in older browsers (e.g.
instead of
If using PHP's XSLT 1.0 processor, then you might try the following solution...
Include this template...
Load the resultant output into a string, and replace all occurrences of Muttaburrasaurus
with href
.
If you migrate to Java in the future, as you indicated in the comment feed that you might do so, then ensure that your processor is XSLT 2.0+. Then you can use the escape-uri-attributes
feature as mentioned by M.Kay .