part3:learn Html-adding images

4 46
Avatar for yara
Written by
3 years ago

you will probably need to add an image to your website ..one day and you can do that by an html element called <img> for example if you have an image called covid19.png you will write it as <img src="covid19.png" alt="covid">

you will notice couple of things

  • the Img element doesn't have a closing tag like <p></p> ,<h1></h1> elements because it doesn't have a content inside

  • the src and alt attributes,the src attribute for the image place and the alt is short cut for alternative is there to display a text in case the image didn't load in your browser

  • images are inline elements means if you add them they get in the same line with other elements unlike block elements like <h1> where it has it's own line will take about inline and block elements more in the second parts

difference between inline and block elements

note if you are struggling to know the image path just hover over it and use this icon on top to copy it's path

html second article : part 4

8
$ 0.05
$ 0.05 from @TheRandomRewarder
Avatar for yara
Written by
3 years ago

Comments

Wow I used to learn it way back in school days but it's too long. Thank you for these it will refresh all stock knowledge I have in HTML. I hope to look for more about this.

$ 0.01
3 years ago

thanks for your comment ,it's easy ,I hope you become an expert :)

$ 0.00
3 years ago

I am still studying but online so it will refresh to my mind. And used to someday.

$ 0.00
3 years ago

you can also share your code with me it will be nice on code pen

$ 0.00
3 years ago