Forms and Struts Question

Hi Everyone,
I am having a problem with Forms and Struts for compliance. 
Here is an example of what I am trying to do with the struts <html:text>

tag. The following code is what we have in the login.jsp file.

	<tr background="<%=root%>/images/color_lt_blue.gif">
		<td width="32%" align="right" class="body" scope="row"><LABEL
FOR="userName"><a name="login"></a><u>L</u>ogin:</LABEL></td>
		<td width="33%"  class="body"><html:text maxlength="20" size="20"
property="userName" accesskey="l"/></td>
		<td width="35%"><html:submit styleClass="button" value="Login"
accesskey=""/></td>
	</tr>

I understand that to make it  508 compliant, we need to have the <LABEL
FOR=""> correspond to the "id" attribute of the <input> tag that is rendered
when the jsp is compiled. To do this, I tried the following. When I tried to
test the page, it did not load - I received a compile error when trying to
add the "id" attribute to the <html:text> tag with the following code.


	<tr background="<%=root%>/images/color_lt_blue.gif">
		<td width="32%" align="right" class="body" scope="row"><LABEL
FOR="userName"><a name="login"></a><u>L</u>ogin:</LABEL></td>
		<td width="33%"  class="body"><html:text maxlength="20" size="20"
property="userName" id="userName" accesskey="l"/></td>
		<td width="35%"><html:submit styleClass="button" value="Login"
accesskey=""/></td>
	</tr>

Please advise as to how to make applications with struts tags 508-compliant.

Thanks
Scott

Received on Tuesday, 14 October 2003 16:33:54 UTC