Home > Net >  HTML image resize
HTML image resize

Time:11-30

enter image description here I'm very new to this, I can't seem to figure out why cant I drag an image to my image folder and also I don't know how to resize my image to fit my website, can someone please help me? I am using vs code enter image description hereenter image description here

I checked on to find available fixes and on mdn however I am confused

CodePudding user response:

You can't drag your image inside your images folder because it's not a folder, for create a folder it's second icon of the left of "Web D..." (the folder where you put HTML - Personal Site) or you can also create it manually in your file manager

For resize your image you can use the style inside your image balise

<img src="" style="height: 100px; width: 100px">

CodePudding user response:

images is not a folder. It's a text file. To create a folder click on the second icon on the left from the name of the current folder (Web D...) - Your HTML - Personal Site folder is inside that folder. Then you will be able to drag it inside. You can also create new folder manually directly from you file manager/explorer.

You can resize your image directly in HTML by adding width and height inside style attribute:

<img src="Steven.png" style="width: 250px; height: 95px;"

Or you can do the same inside CSS:

img {
   width: 250px;
   height: 95px;
}
  • Related