4 ms·
The two most popular are a crock: * Required attribute alt missing: Most images are decorative, having alt is pointless in most cases. Should be optional. * &
by snorkel 14y ago
The two most popular are a crock:
* Required attribute alt missing: Most images are decorative, having alt is pointless in most cases. Should be optional.
* & didn't start a character reference: proving this was a bad choice for an escape character to begin with
- drhowarddrfine 14y agoYou reeaallly don't know what you're talking about.
- olavk 14y agoYou indicate than an image is purely decorative by providing the attribute value `alt=""`.
- icebraining 14y agoWhich provides no more information than no alt attribute at all.
- pornel 14y agoNo, it allows screen readers to distinguish between potentially important images with missing alt (author didn't care) and images that are known to be unimportant (author explicitly specified it).
- kalleboo 14y agoAnd requiring alt means you lose that signal, since content providers will continue to be lazy and leave the alt blank, so now all images look like they're decorative, instead of some being "we don't know". You can't solve a social problem (content providers who don't care) with a technical limitation (required alt tags).
- olavk 14y agoIf a content provider don't care about accessibility, why would they care about validation? They can leave out the alt-attribute whether it is required by the spec or not.
- kalleboo 14y agoBecause they're all using wordpress/blogger/etc which put it in for them.
- olavk 14y agoIf the developers lets these tools insert `alt=""` per default with all images, then they are not in compliance with the spec.
- kalleboo 14y agoBut if they leave out alt="", then they won't validate. What are they supposed to do, force the user to enter text? Then you'll end up with alt="sldfjsjf".
- olavk 14y agoNo, it is correct according to the HTML5 spec to leave out the alt-attribute if there is no valid alternative text available.
- DanBC 14y agoNo, it shows the author has thought about alt attributes and has included them because doing so is standards compliant. For images that are purely decorative including an empty alt attrib is valid. People using screen readers (and people with images turned off[1]) don't need to hear (or read)"SMALL RED BULLET" for all 7 items in the list. [1] I often have images turned off. I'm using a mobile broadband dongle. My ISP uses horrible proxies to compress images. I'm in the UK. The IP of the proxies is 1.2.3.9 through 1.2.3.12 - this is sub-optimal for many obvious reasons. Bypassing this proxy is trivial, but means I download a lot more data.
- moreati 14y agoI'm guessing a 3G provider other than Three or Vodaphone - said proxy is why I left T-Mobile. Last I tried you can instruct the proxy not to alter your web traffic using HTTP cache control headers e.g. http://www.lewiz.org/2007/01/hacking-t-mobile-web-proxy.html http://www.lewiz.org/2007/01/hacking-t-mobile-web-proxy.html
- DanBC 14y agoYes! They re-write webpages to insert a bunch of script, which re-writes all alt tags to instructions for fetching higher quality images for this or all images on the page. It is annoying. They also have a psuedo-random interstitial telling me that I'm over the "fair use" allowance. The only reason I'm still using them is that they don't charge for MB or GB; I pay for three months and get "unlimited surfing". They block some stuff after you hit 1GB, but that's trivially easy to get around. Which I do, since they've said I get unlimited web use.
- wazoox 14y ago> For images that are purely decorative including an empty alt attrib is valid. People using screen readers (and people with images turned off[1]) don't need to hear (or read)"SMALL RED BULLET" for all 7 items in the list. I typically use "-" or "*" as an alt for bullet images in text, and similar decorative markers. It seems to make more sense to me to emphasize that there's a list.
- olavk 14y agoYes it does. It provides the information that the image is purely decorative and can be ignored in a text-only representation.
- toemetoch 14y agoThe alt field specifies the text to be shown in the container when the resource is missing. If you don't use it you'll get an eyesore in the form of a broken image icon, within a reserved space for the resource. The alt="" instructs the browser to minimize space reserved for a missing resource. This is indeed useful for layout elements that are only a few pixels on each side. This way you don't mess up layout. It's used to keep the UI usefull when things go missing.
- DanBC 14y ago> Required attribute alt missing: Most images are decorative, having alt is pointless in most cases. Should be optional. NO. ALT attribute must not be optional. Just put an empty alt in for decorative images and learn how to do sensible alts or long_desc for other images. And many of the supposedly decorative images are used functionally, in which case they need proper alts.
- bickfordb 14y agoI agree, the specification seems to set authors up for failure. I never understood why the language needed & followed by WHITESPACE to be escaped. It seems like it would be pretty easy to ignore this sequence in a parser?
- voyou 14y agoAFAIK, using an ampersand character to represent an ampersand, rather than starting a character reference, is no longer a parse error in HTML 5 if it occurs in an attribute. See: http://dev.w3.org/html5/spec/tokenization.html#consume-a-character-reference http://dev.w3.org/html5/spec/tokenization.html#consume-a-cha...