Problem:
Most surprised to discover an image module ignoring the alt tag in its XHTML output. How can this be? This causes major problems with search engines which look for (1) valid XHTML (fails on missing "alt" and the "data-link" attribute) and (2) for file names and alt tags for image assets. Although having the tag does little for seo, not having it causes real issues, dramatically reducing the efficacy of this fine module.
Solution(?):
"Alt" and "Title" fields available in the media>edit page and I'd also expose these to the upload widget. Obviously we could hard code these into the module(s), but a more forward-looking approach for this fine family of media modules might be an array of tag sets/doctypes, each containing valid value(tag)-key pairs for the various media types. Media API exposes these to individual upload or insert modules.
Comment | File | Size | Author |
---|---|---|---|
#1 | 1091568-alt.patch | 603 bytes | meba |
Comments
Comment #1
meba CreditAttribution: meba commentedI think there are two parts to this issue. First is solving the missing alt which invalidates the page in Validators, second is a better solution. It would be great if we could solve part 1 right away...
Patch attached. I just changed a static to theme('image') which automatically adds empty alt and all required tags
Comment #2
JacobSingh CreditAttribution: JacobSingh commentedCommitted the above.
Changed the title to reflect the new feature we should implement to give the alt tag meaning.