Welcome to WebmasterWorld Guest from

Forum Moderators: not2easy

Message Too Old, No Replies

Image Border

img border



9:36 am on May 5, 2010 (gmt 0)

5+ Year Member

i tried to many times to do it but it is still not working
how can i fix it

.gimg{max-height:300px; margin:20px; padding:10px;

<asp:Image ID="Image1" runat="server" CssClass="gimg"/>

the border is not appear.


9:58 am on May 5, 2010 (gmt 0)

5+ Year Member

Hi Fedail,

You could try this out, though it is an internal css.

I think you have missed the imageurl part in the tag.

<asp:Image ID="Image1" runat="server" imageurl="images/someimage.jpg" style="border: 5px solid blue"/>


10:29 am on May 5, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

Also validate your HTML. If it's xHTML strict you'll need a space before the trailing slash e.g.

<asp:Image ID="Image1" runat="server" CssClass="gimg" [space here]/>


11:47 am on May 5, 2010 (gmt 0)

5+ Year Member

it is working here but in the stylesheet not working
i didn't face this problem before

Featured Threads

Hot Threads This Week

Hot Threads This Month