0
For insert image, must with tag <img src="blablabla.com" alt= "" /> . The question is, what the function of tag alt="" ? Thnks
HTML
10 odpowiedzi
+ 12
Yaaap, alt attribute must be specified for those who have visual problems, the alt attribute is readed by the vocal speaker to help them... remember that the attribute have to contain an alternative description and not a title for the image.
Another good practice is set a title attribute for your HTML elements, because when you'll drag your mouse on an element there will be a little pop-up with the title, also good for those who have visual problems. Google uses that attribute to describe their services and how to use every single element.
With HTML5 you can use the title attribute on any HTML element.
If you want to be professional, remember that accessibility is one of the most important thing while developing a website, web is for all. ;)
PS - Kuba preceded me. :(
+ 9
alt is crucial for tagging images for search engines. If you are placing an image of a black horse and give the alt description as "black horse running", google, bing and other search engines will place this image in their 'images' tab when someone is searching for "black horse running".
Also, a good practice for making your webpage accessible for people with disabilities. Professional parsers not only know how to pronounce a text which is marked as <strong> or <em>, but also know how to deal with images, if they have their alt attribute filled in properly.
Bottom line: it's always good to add alt to <img> ;)
+ 4
the alt Attribute shows if the src file does not exist or there's an error loaing it
+ 4
if it's blank it doesn't mess anything up, and div tags r container tags that separate the inner content from the rest, just to keep things more organized and you could also style divs differently
+ 4
no prob
+ 4
another reason to add alt attribute is users with low bandwidth or mobile users. these people tend to "turn off displaying images" when they browse, and if they found that your site doesn't have an alternative text they would leave it immediately and wouldn't visit it again.
+ 4
@Maz ;)
+ 1
thanks all, and thanks @Maz :)
0
are if im not iserted it is no problem? and one more question, what the function tags <div> ? thanks
0
thank you so much bro