I have started using struts .I have hanged in a place ,Code is bellow
<st:submit src="getText('image.user.login')" type="image" height="21" width="44" </st:submit>
when i run this code , getText('image.user.login') message does return any value , But when i replace src="getText('image.user.login')" with value="getText('image.user.login')" than it returns value of "image.user.login" from property file.
What is reason for it , and how can i solve this issue ?
Thanks in advance
like this example illustrates in this reference submit reference struts
Render an image submit:
<s:submit type="image" value="%{'Submit'}" label="Submit the form" src="submit.gif"/>
src : Supply an image src for image type submit button. Will have no effect for types input and button.
AND
value : String Preset the value of input element.
this should answer your question if you use src you should assign a path and if you use value you can use a preset value