Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using bean:write with html:link

 
SivaC Kumar
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to send a value as a request variable to action class.But I am getting an exception.
My code is
<logic:iterate name="searchResultsForm" id="results" property="searchResults" type="com.ng.wft.wl.form.SearchUserForm" scope="session">
<tr>
<td><html:link action="/searchUser.do?user=<bean:write name="results" property="userId"/>&methodToCall='showDetails'"><bean:write name="results" property="userId" /></html:link></td>
<td><bean:write name="results" property="firstName" /></td>
<td><bean:write name="results" property="lastName" /></td>
</logic:iterate>

but it is giving a servlet Exception


[ServletException in:/content/jsp/admin/searchResults.jsp] /content/jsp/admin/searchResults.jsp(24,73) equal symbol expected'

this is code where the exception is coming

><html:link action="/searchUser.do?user=<bean:write name="results" property="userId"/>&methodToCall='showDetails'"><bean:write name="results" property="userId" /></html:link></td>


Can any one help me Plz!!!
 
Satish SN
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Siva,

i think ur line has a formatting problem ie u cannot have double quotes inside a double quotes ie for all the request params u r mentioning in the html:link u should use '' instead of "" u check and try format correctly then u r problem would be solved.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic