Welcome visitor
* Login
* Register
It is currently May 20th, 2019, 6:39 am
All times are UTC [ DST ]
* Search
View unanswered posts - View active topics

FORUMS » Client Side » HTML



Post new topic Reply to topic  [ 2 posts ] 
Author Message
  What size are images displayed on HTML?
PostPosted: December 4th, 2009, 6:09 am 

Posts: 14
When I use an image on HTML, is it displayed on its real size or does the browser makes it fit in the page? What if I want to show it bigger or smaller than the actual size, do I need to have many images for that?


Top
 Profile  
 
  Re: What size are images displayed on HTML?
PostPosted: December 4th, 2009, 8:22 am 
User avatar

Posts: 63
Browser will show the image on its real size and you can change that (not needing to have an image for each size) with the CSS style attributes:
<img src="image.bmp"> <!--this is the normal size-->
<img src="image.bmp" style="width:100%"> <!--this is the 100% of the screen-->
<img src="image.bmp" style="width: 30px"> <!--this is going to resize the image to 30px wide-->
<!--you can do the same with the height attribute, but you are
encouraged to not use both at the same time so you can keep the ratio-->


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

FORUMS » Client Side » HTML


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron