How to code an image in html? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How to code an image in html?

I tried the <img> tag but couldn’t attach an image

21st Jul 2022, 12:19 PM
munaym hossain
munaym hossain - avatar
3 Answers
+ 2
What exactly did you try? Please link your code!
21st Jul 2022, 12:24 PM
Lisa
Lisa - avatar
0
when attaching the image you should also check the path if it is the same path you are using in your <img> tag.
21st Jul 2022, 12:51 PM
john mark arellano
john mark arellano - avatar
0
It should look like this: <img src = "Image Address" alt = "Optional Title for your image"/> You may have accidentally copied the image than the image address, I frequently made that mistake when learning HTML/CSS.
21st Jul 2022, 1:23 PM
ً