Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

image path goes wrong.

 
roby george
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I have a login page in my application, In that i am using a login image.
I am accesing that image like bellow
<img src="${images}medical.png" width="285" height="148" />
the image variable is comming from
<c:url value="${LinLogin.imagesPath}" var="images"/>
LinLogin is bean and imagePath is a string getter/setter, i am populating this getter/setter in prerender method.
When i m invoking my application the login page display but the image is not comming, I check the source code of that pafe the image path shows me like bellow
<img width="285" height="148" src="/lin/resources/theme/default/images/;jsessionid=54BE595C60CED84F4E5F701ED0752193medical.png"/>
it should be like bellow
<img width="285" height="148" src="/lin/resources/theme/default/images/medical.png"/>

the jsessionid=54BE595C60CED84F4E5F701ED0752193 is autometicaly apend in image path so thats why my image is not displaying the image path gows wrong.

Can anybody gives me suggestion/ideas how to solve this issue.




 
Guy deLyonesse
Ranch Hand
Posts: 200
Eclipse IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the line



Is the String variable for your image path stored in an object called images? If so then the syntax should be


Note the use of # instead of $ also.


 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic