Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Image in template doesn't show

Quote Reply
Image in template doesn't show
Hi !

I created a File column in my db for an image. I store the files in a root dir called 'pics'. When I add a link, the image uploads ok, as well as the view and download commands when I check what has been stored.

Now, I want to Insert this image in my template, I write :

<% if Image%>
<img src="<%Image%>">
<%endif%>

and when I view the source of this html page, <%Image%> is equal to flag.jpg which is my image. So I tried

<% if Image%>
<img src="<%build_root_url%>/pics/<%Image%>">
<%endif%>

And I find out flag.jpg has been stored by links SQL in a new folder called '1' inside '/pics' and the image url now is equal to

http://mysite.com/pics/1/1-flag.jpg

How can I insert this image in a template ? Is there a way to get to this new path/url ?

Thanks.

Mitia
Quote Reply
Re: [mitiamitia] Image in template doesn't show In reply to
Sorry, posted too quickly,



answer is here :

http://www.gossamer-threads.com/...obal%20image;#184347

Mitia
Quote Reply
Re: [mitiamitia] Image in template doesn't show In reply to
You could also pass in the id to jump.cgi