+ 2
What is alt in img tag
please clarify the dot
7 odpowiedzi
+ 16
there are some probabilities that an image would just not load in a browser or the user has disabled images for data saving or any other issues.
At that time, alt will work as a substitute text informing what the image is about.
<img src="girl.png" alt="a girl with an umbrella">
so the above example tells us that if the picture fails to load, "a girl with an umbrella" text will appear in the image box instead.
+ 4
whenever you attach an image link there's a chance something might go wrong either due to a wrong src links or other reasons.in these the alt has to be displayed
+ 4
Alternative text- alt
+ 3
alt is said to be alternative text in IMG tag we can use as attribute and when image fails the alternatively the text is displayed
+ 2
it's an alternative text which will get displayed in place of image if image fails to load via browser get request (404) or if images are disabled by user for data saving
+ 1
the alt is also important for SEO and search engines.its also neccesary for people who use sreen readers for checking the web; I'm talking about blind people!
0
Alt means the alternative tag