0

I am using the html:image tag to include images in the jsp. the image location is specified in the message resource properties file of struts. the paths are defined as ../../images/image1.gid previously. now the context is changing due to some reason, so the images are not being loaded. how do i access the context path in the message resource file? i tried key={0}/images/image1.gif, but this works only for the bean:message as it contains arg0 attribute. but how i do for the image? any round about way?

PS: <img src=<bean:message arg0="<%=request.getContextPath()%>" key="image1"/>> works. but i cant change in 100s of jsp files which uses html:image.

thanks V

Rupesh Yadav
  • 12,096
  • 4
  • 53
  • 70
Vijay
  • 21
  • 1
  • 3

1 Answers1

0

but i cant change in 100s of jsp files which uses html:image.

Use a text editor with Find & Replace in All Open Files facility, like Editplus and Notepad++.

BalusC
  • 1,082,665
  • 372
  • 3,610
  • 3,555