I could use some help creating an XSL template that will take a string of numbers (i.e., 123456789) and format that string into a Social Security Number format (i.e., 123-45-6789). I found one example on the Internet, but it seemed overcomplicated.
I’m new to XSLT, so please keep that in mind when replying. Thank you!
XSLT 1.0’s string functions are a bit limited, but fortunately this isn’t too hard:
Assuming < ssn >123456789< /ssn>:
In XSLT 2.0, concat() can take more than two arguments, so it’s a single line: