« Web, HTML, Tech Forum

Image size

Posted by Sarah♡

posted

Forum: Web, HTML, Tech

How do I make an image smaller?? 


Report Topic

3 Replies

Sort Replies:

Reply by Exzelt

posted

img
{
    width:x px;
    height:y px;
}

or
img
{
    width:x%;
    height:y%;
}


Permalink Report Reply

Reply by Sarah♡

posted

Reply by Dustin

posted

If you don't want to resize the image using CSS (because it will probably resize every image to match those metrics), you can change the HTML for that specific image doing something like:

<img src="http://picture.com/picture.jpg" height="200px" width="200px" alt="popup text when mouse is hovered">

The height and width modifier can either be in pixels (px) or percentage (%).
The alt modifier is optional, but will make text popup when you hold your mouse over the image.


Permalink Report Reply