Forums
This topic is locked
Dynamic Image Resizing in a Constrained area
Posted 12 Jan 2006 16:38:22
1
has voted
12 Jan 2006 16:38:22 allan khalil posted:
I was reading your tutorial on "Proportional Image Resizing within a ConstrainedArea", I'm trying to get it working with dynamic images? I tried using the
following command:
<b><img src="<img
src="<%=(rs_mainart.Fields.Item("pix".Value)%>"><%=ImageResi
ze(rs_mainart.Fields.Item("pix", 100, 100)%> </b>
Having the command close and open again, i know is wrong but what would be the right code?
Please help... Much appreciated.
Replies
Replied 12 Jan 2006 18:09:06
12 Jan 2006 18:09:06 allan khalil replied:
hi,
I have updated the source...
<b>
<% if (rs_mainart.Fields.Item("pix".Value) <> "" then
myIMG ="/Admins/Head/images/" &(rs_mainart.Fields.Item("pix".Value)
Else
myIMG = "'i/Admins/Head/images/' name='noimage' width='200' height='100' id='noimage'"
end if
%>
<img src="<%=myIMG%>"></b>
The image still stays as is.
Edited by - khalilah on 12 Jan 2006 18:24:53
I have updated the source...
<b>
<% if (rs_mainart.Fields.Item("pix".Value) <> "" then
myIMG ="/Admins/Head/images/" &(rs_mainart.Fields.Item("pix".Value)
Else
myIMG = "'i/Admins/Head/images/' name='noimage' width='200' height='100' id='noimage'"
end if
%>
<img src="<%=myIMG%>"></b>
The image still stays as is.
Edited by - khalilah on 12 Jan 2006 18:24:53