|
Re: path for image reference [message #689944 is a reply to message #689825] |
Tue, 28 June 2011 15:55 |
|
Mike
Can you try something like the following in your text element:
<div id="testimg">
<img id="myimg"
src=<VALUE-OF>reportContext.getHttpServletRequest().getContextPath()
+"/webcontent/birt/images/Go.gif"</VALUE-OF> alt="my alt text" />
</div>
Hopefully you will not need it but you can check if you are in the
designer like:
if(
reportContext.getHttpServletRequest().getAttribute("attributeBean").isDesigner()
){
BTW not sure if you read this but look at this post on images:
http://birtworld.blogspot.com/2010/09/birt-image-report-item.html
Jason
On 6/28/2011 8:46 AM, Mike Wulkan wrote:
> Hi,
>
> I have the following reference in a text control:
>
> <img id="twistyImg_08" src="WebContent/report/images/CollapseInfoIcon.gif"
>
> This works fine during development when I display the report in the
> viewer, however when the report is deployed to the server, the server
> can no longer find the image. I believe the "WebContent" part of the
> path is not required during deployment but is required in the
> development environment.
> How can I make it so that the image works in both scenarios?
>
> Thanks,
> Mike
|
|
|
|
Powered by
FUDForum. Page generated in 0.02099 seconds