If we giving the path to image why that "alt" is need? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

If we giving the path to image why that "alt" is need?

What is mean by image describe in "alt"

26th Aug 2019, 1:44 PM
anuka sanjaya
anuka sanjaya - avatar
13 Answers
+ 7
anuka sanjaya Your statement is correct. The image source may not be permanent, so if the source is removed, the image will not be able to show, and your alt text will be shown instead.
26th Aug 2019, 2:16 PM
Hatsy Rei
Hatsy Rei - avatar
+ 5
alt is displayed if image fails also alt is used for visually impaired via a module which actually tells the impaired what is ... *explanation https://yoast.com/image-seo-alt-tag-and-title-tag-optimization/amp/
26th Aug 2019, 1:59 PM
BroFar
BroFar - avatar
+ 4
heyy please chec the lesson on images In case the image cannot be displayed, the alt attribute specifies an alternate text that describes the image in words. The alt attribute is required.
26th Aug 2019, 1:46 PM
Hum!_Kad
Hum!_Kad - avatar
+ 3
The visually impaired can take advantage of information from voice-over app on their devices!
26th Aug 2019, 4:11 PM
Peter Ohue
+ 2
Lets think i am giving src for image and image not in their then alt is displayed am i right?
26th Aug 2019, 1:48 PM
anuka sanjaya
anuka sanjaya - avatar
+ 2
Think of alt= attribute as a picture description like we use the meta description or a schema description... It is read by the search engines as well... It helps index images ... *note this is part of search engine optimisation / optimization and often overlooked by developers.
26th Aug 2019, 3:12 PM
BroFar
BroFar - avatar
+ 2
u dont hav to put the alt in only if ot fails to load then yoi describe the pic like a picture of a brown dog then u will say alt=“dog-with-brown-fur” alt is were u describe the pic plz follow if this helps
26th Aug 2019, 3:29 PM
Hum!_Kad
Hum!_Kad - avatar
+ 2
Latest Prince Hi Hi by itself is not giving relevant content to any of the 3 threads you have posted in so far. I see that you are new here but this is considered as spamming... which is seen as a negative behavior. Please read the content guidelines! https://code.sololearn.com/WNo9MMla940n/?ref=app and follow the do nots https://code.sololearn.com/Wv5gTHy1N6Ji/?ref=app https://www.sololearn.com/discuss/1316935/?ref=app
27th Aug 2019, 8:31 AM
BroFar
BroFar - avatar
+ 1
Well alt stands for alternative text the text inside the alt attribute will be shown only well image failed to load or when we write wrong path , meaning is simple when some situation occur where image is not able to show then the text you wrote inside alt attribute will be shown in browser Example <img src="let's say I have mentioned wrong path of image here" alt="oops! image failed to load"> Output:- oops! image failed to load This output because I have entered wrong path of image their are many more case like after entering path I have move to image to the another folder and so on.. Hope This with help you :)
26th Aug 2019, 2:38 PM
Puneet
+ 1
Browsers can be set to not show images (for speedier download). I think (but not 100% sure as it's been years since I've done any html) that... what ever you put in the 'alt' keyword will show up instead. Before broadband, all we had was (max) 56 kps modems.
26th Aug 2019, 7:52 PM
rodwynnejones
rodwynnejones - avatar
+ 1
If you don't put alt and your image would not found in your code, then the alt will describe about the image. Hope u understood..!
28th Aug 2019, 2:41 AM
Jayam Varma
Jayam Varma - avatar
0
If due to some reason your image doesn't loads then this alt attribute will come in handy for you. It just displays alternate text for your image. For example: when the path of image provided by you is wrong, alternate text for image will be show instead of a image so it is a best practice to use alt attribute for images.
27th Aug 2019, 5:10 AM
Omkar Gosavi
Omkar Gosavi - avatar
0
It's a common practice especially if you want to work with XML
27th Aug 2019, 10:04 AM
Maxx
Maxx - avatar