+ 3

Facing problem in using img tag.

I have used img tag with the source of the pic but failed. there was a box showing for the picture but not the picture. Help pls.

2nd Dec 2016, 2:18 AM
Aritro saha
Aritro saha - avatar
6 Answers
+ 5
I think you are getting problem with path you can put the .jpg file in same folder as .html and then SRC will image name.jpg <IMG SRC=flower.jpg> see Aquarius codes
2nd Dec 2016, 6:45 AM
Sandeep Chatterjee
+ 5
yes Aquarius told correctly here is example <IMG SRC="flower.jpg" alt="this text is alternative text if image is not available" /> alt is optional
2nd Dec 2016, 1:02 PM
Sandeep Chatterjee
+ 4
<img src="http://www.nationalgeographic.com/content/dam/animals/pictures/mammals/g/gray-wolf/gray-wolf_01.ngsversion.1474903032262.adapt.1190.1.JPG" alt=" "/> This is just an example of what it should look like. Make sure: 1.) its in between the body tags 2.) You use "image adress" and not "link adress" 3.) you dont forget the quotes that the link is in Hope i was helpful to you :)
2nd Dec 2016, 2:31 AM
Aquarius
Aquarius - avatar
+ 3
Check out some of the codes i have that have images. They might help you out too :)
2nd Dec 2016, 2:32 AM
Aquarius
Aquarius - avatar
+ 3
alt is the alternative text that shows up if the picture doesn't show up on some browsers. Make sure its alt=" "/> if you dont have the = it wont work. Hope i was helpful to you :)
2nd Dec 2016, 12:22 PM
Aquarius
Aquarius - avatar
+ 1
what's the use of alt""/> ?
2nd Dec 2016, 12:01 PM
Aritro saha
Aritro saha - avatar