It looks like the span was generated solely for the purpose of providing a place to hang the tag's id value. Which is a problem, since you already generated a tag with the same ID, thus violating the uniqueness requirement. The choice of "span" was undoubtedly because it's probably the only HTML wrapper that wouldn't alter the page layout.
I try to avoid doing custom JSF tags as Java code at the moment. I don't trust the mechanisms to remain stable. And it's easier to implement custom controls and the like as XML custom tags, instead. I recommend doing some serious manual reading, though. There's probably a way to switch off the automatic wrapper generation. Although the fact that the span follows your generated code instead of wrapping it probably indicates you haven't followed the protocols properly anyway.
An IDE is no substitute for an Intelligent Developer.
mooooooo ..... tiny ad ....
the new thread boost feature: great for the advertiser and smooth for the coderanch user