you probably have to include the whole expression within your
expression element,
for instance:

<html:link href='<%= "javascript:submitForm(\'" + i + "\')"%>'>value</html:link>

should work, but a bit ugly ;-)

maybe it looks nicer using jstl !
<c:forEach var="i" begin="1" end="5" step="1">
  <html:link href="javascript:submitForm('${i}')">var</html:link>
</c:forEach>

Hope it helps
Yannick

On 9/10/07, Anna Simbirtsev <[EMAIL PROTECTED]> wrote:
> Hello
>
> I am trying to pass the value of i to a javascript but I can't seem to get
> it to pass the value.
>
> <% for (int i = 0;i < 5; i++) { %>
>     <tr>
>             <td align=left>
>                  <html:link href="javascript:submitForm('<%=
> i%>')">value</html:link>
>             </td>
>     </tr>
> <%}%>
>
> What am I doing wrong?
>
> Thank you
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to