Hi,
Consider <foo> </foo> and <foo/>
"string-length(anElement) > 0" will return true for the first one,
"normalize-space()" will return false for both.
True!
I guess what the original author really meant was to check if the
element is "empty or non-white" - because the data stored in anElement
would be a car's license number and it makes no sense to return spaces
(which are invisible on the print-out) when there's alternative data
stored (which he retrieves in the otherwise-branch).
I reckon my test with normalize-space() is more accurate.
Thanks,
Ralph