Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
The moose likes Struts and the fly likes HTML validation with struts tags Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "HTML validation with struts tags" Watch "HTML validation with struts tags" New topic

HTML validation with struts tags

Gezza Hall
Ranch Hand

Joined: Jan 04, 2005
Posts: 33
Hi guys.

I'm trying to get my HTML to validate to HTML standards, but my form elements are failing.

The following line in my code:

translates to:

This doesn't validate, as there is no closing slash, ie

Any suggestions please?
Franck Tranchant
Ranch Hand

Joined: Aug 07, 2003
Posts: 75

Try this :
Using this tag in a page tells all other html taglib tags to render themselves as XHTML 1.0.
As a result, the closing brace will be added when closing elements.
[ March 16, 2005: Message edited by: Franck Tranchant ]

Craig Jackson
Ranch Hand

Joined: Mar 19, 2002
Posts: 405
I believe the html struts tag has adhered to the HTML standards. The end tag for input element is not required, in fact I believe it is "forbidden".

Input Element

I am not sure if this is what you are asking. So I hope it helps.
Gezza Hall
Ranch Hand

Joined: Jan 04, 2005
Posts: 33
Excellent, thanks guys.
I agree. Here's the link:
subject: HTML validation with struts tags
It's not a secret anymore!