Image paths
Posted: 12 January 2011 05:36 PM   [ Ignore ]
Wallflower
Rank
Total Posts:  5
Joined  2011-01-09

Hi.

I have swapped over our photoblog to using the safecracker file upload field.

when I test the field it shows the full url and the image displays fine.
my previous uploads only display the file name not the full url so do not show an image.

what is the best approach to getting all the old images to work

{exp:channel:entries channel="photoblog"}
<p>{photo}</p>
{exp:imgsizer:size  base_cache="mypath"  src="{photo}" height="110" width="110"}
<img src="{sized}" class="sideimage"  width="{width}" /></a>
{/exp:imgsizer:size}
{
/exp:channel:entries} 

This code produces a full url and successfully displays an image for the file I uploaded using safecracker file.
previous uploads only show the file name so dont work with src.

thanks very much


Jon

Profile
 
 
Posted: 12 January 2011 08:12 PM   [ Ignore ]   [ # 1 ]
Teen Scream
Avatar
RankRankRank
Total Posts:  3541
Joined  2009-05-29

What kind of field were your previous uploads?

Profile
 
 
Posted: 12 January 2011 08:26 PM   [ Ignore ]   [ # 2 ]
Wallflower
Rank
Total Posts:  5
Joined  2011-01-09

‘File’ (v.3.1.1) by Mark Hout

This was on out EE1 site which is being transitioned to EE2.

Profile
 
 
Posted: 12 January 2011 08:27 PM   [ Ignore ]   [ # 3 ]
Teen Scream
Avatar
RankRankRank
Total Posts:  3541
Joined  2009-05-29

Please check this thread for some advice: http://expressionengine.com/forums/viewthread/162693/

Profile
 
 
Posted: 12 January 2011 08:45 PM   [ Ignore ]   [ # 4 ]
Wallflower
Rank
Total Posts:  5
Joined  2011-01-09

Yup ok thanks!
SQL time.

Profile