Our team of 体育平台app Web Design gurus are standing by to assist you achieve your online marketing goals.


体育平台app Web Design, LLC aims to improve business by delivering effective solutions based on innovative technologies and professional designs. Discover the variety of services we offer and convince yourself on the basis of the latest works that we've done. We love building fresh, unique and usable websites optimized specifically for your niche.

Responsive Web Design

体育平台app / SEM / Social Media

Conversion Rate Optimization

Email Marketing

Online Presence Analysis

体育平台app Web Design  /  Web Design  /  Your Image Is Probably Not Decorative


About The Author

Eric is a Boston-based designer who helps create straightforward solutions that address a person’s practical, physical, cognitive, and emotional needs. More about Eric ↬ [1]

Image placement on the modern web is highly intentional, helping to communicate the overall purpose of a page or view. This means that nearly every image you declare needs to have an alternate description.

The img element’s alt attribute [2] can be “nulled,” which is the act of setting it to an empty string instead of a text description. Nulling an alt description means there is no information between the opening and close quotes. If there is an empty space, it will not be considered nulled:

This image has been nulled.
This image has not been nulled.

What Does “Decorative” Mean?

Nulling an image indicates that it is for decorative purposes only.

In this context, decorative means that the image does not visually communicate information that is important to understanding the purpose of the page or view, and why the image is included as a part of that.

Decorative does not mean that the image contains content that is considered as decoration. [3]

For example, a website that sells wallpaper will want to have alternate descriptions for wallpaper samples:

																Small red and white illustrated umbrellas on a teal background.

Another example could be a museum website, where presenting a piece from their collection could benefit from both an alternate description and a caption [4] :

A tile painting, composed of 33 Delft tiles forming a view of the port of Rotterdam. Set in a modern mahogany frame, with gilded inscription on bottom border.
View of Rotterdam, by Cornelis Boumeester. Date: about 1700–20. Accession Number: 2005.1057. In Dutch homes, tiles typically served utilitarian purposes, such as covering the walls of kitchens, utility rooms, passageways, and fireplace surrounds.

Make sure that your alternate description includes punctuation [5] , as well!

Why Would You Want To Make An Image Decorative?

Assistive technology will skip over nulled images and not announce their presence. The reasons for wanting to do this are mostly historical.

Old Layout Techniques

Early web development techniques relied on images to help them guarantee consistent layout across different operating systems, browsers, and browser versions. The most common example of this was a spacer.gif [6] , a 1×1 transparent pixel that was stretched to different sizes to push content into place.

Three stretched spacer.gifs used to create an outer margin for the text, “Welcome to my homepage.”
Three stretched spacer.gifs used to create an outer margin for the text, “Welcome to my homepage.” ( Large preview [7] )

This technique would typically use many spacing images to create a visual design. Without a way to silence their presence, these images would clutter up what assistive technology announced and make it confusing and time-consuming to navigate and take action on web content.

Old Design Techniques

Before there were CSS properties such as box-shadow [8] , developers had to use techniques that chopped up the decorative styling to make it work with content of indeterminate height or width. This technique was called 9-slice scaling [9] , a term that refers to the 9 sections of content you would need to create.

The text, “The 9-slice scaling technique used repeating background images for content with a flexible width or height.” surrounded by columns and rows for each of its four sides. In each of the four corners is a square area. In the square areas and columns and rows are generic image icons. The image icon repeats in the columns and rows, demonstrating how a texture can be tiled.
The 9-slice scaling technique ( Large preview [10] )

Much like spacer images, 9-slice scaling used multiple images to create the desired visual effect. And, much like spacer images, the only way to remove the clutter these images created was to mark them as decorative.

Redundant Announcements

There is the rare scenario where an image is repeated on a page or view, and it’s repeat placements don’t supply any additional context. You should be careful about marking an image decorative in this situation, as the lack of an announcement for a visible image may be confusing for someone with low vision who is using a screen reader [11] .

Supplemental Icons

Links and buttons that use icons should always have an accessible name [12] that communicates functionality. If the design also incorporates an icon, the icon’s design does not need to be communicated.


If the component only uses an icon, the image itself should be used to create the accessible name:


Note that a visible text label is the preferred technique. A visible text label can be translated [13] and communicates purpose more directly [14] .

I have no idea what this button does.

Contemporary Use

Modern CSS layout [15] and styling techniques means that image placement is now highly intentional. This means that if an image is used, it is most likely going to need an alternate description.

Alternate descriptions should communicate the image’s purpose . That includes the image’s content, but may also include the reason it is included in context on the page or view it has been included in. This is one of the reasons why alternate image descriptions will never be able to be fully automated [16] .

Other Ways Of Displaying Images

There are a few other ways to display an image on a page or view. It is important to ensure an alternate description is provided if the image contains meaningful content — regardless of the technique utilized.

The picture Element

The picture element [17] does not have an implicit role [18] , meaning that its presence does not communicate any purpose to assistive technology. This means it can’t be used to semantically describe the presence of a “picture.”

The picture element is a container for source and img elements. Use the img element’s alt attribute to provide an alternate description for the parent picture element.

Background Images

We can use CSS to declare an image as a background on an HTML element. This is most often used to add a sense of texture to a design.

However, another popular technique is to use a background-image to place an image in such a way where the developer will not have control over the size of the image someone uploads. background-image , combined with other properties such as background-size [19] will ensure that content of an unknown size is displayed without breaking the design.

See the Pen [Background Image As Foreground Image Example]( by Eric Bailey [20] .

See the Pen Background Image As Foreground Image Example [21] by Eric Bailey [22] .

In a scenario like this, our old friend spacer.gif might be helpful again [23] !

Inline SVG

SVG can be displayed by either linking to it via the src attribute in an img element, or by placing the SVG code inline in the page or view.

If you are using inline SVG, you need to use SVG’s title (and potentially desc ) element [24] in place of an alt attribute.


Equivalent Experience

In modern web design and development, displaying an image is a highly intentional act. Alternate descriptions allow us to explain the content of the image, and in doing so, communicate why it is worth including .

Just because an image displays something fanciful doesn’t mean it isn’t worth describing. Announcing its presence ensures that anyone, regardless of ability or circumstance [25] , can fully understand your digital experience.

Further Reading on SmashingMag:

Smashing Editorial (vf, il)


  1. ^ More about Eric ↬ (
  2. ^ alt attribute (
  3. ^ Decorative does not mean that the image contains content that is considered as decoration. (
  4. ^ both an alternate description and a caption (
  5. ^ includes punctuation (
  6. ^ spacer.gif (
  7. ^ Large preview (
  8. ^ box-shadow (
  9. ^ 9-slice scaling (
  10. ^ Large preview (
  11. ^ someone with low vision who is using a screen reader (
  12. ^ an accessible name (
  13. ^ can be translated (
  14. ^ communicates purpose more directly (
  15. ^ Modern CSS layout (
  16. ^ why alternate image descriptions will never be able to be fully automated (
  17. ^ picture element (
  18. ^ an implicit role (
  19. ^ background-size (
  20. ^ Eric Bailey (
  21. ^ Background Image As Foreground Image Example (
  22. ^ Eric Bailey (
  23. ^ our old friend spacer.gif might be helpful again (
  24. ^ use SVG’s title (and potentially desc) element (
  25. ^ anyone, regardless of ability or circumstance (

Powered by WPeMatico

Smashing Magazine is a website and eBook publisher that offers editorial content and professional resources for web developers and web designers.

英雄联盟竞猜视频比分 江湖电竞(南宁)赛表赛事 安博电竞查询直播网站 英雄联盟竞猜直播比赛网址 熊猫电竞排名今日 泛亚电竞赛事手游(泛亚电竞注册官网v6.3 IOS版)