Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Accessibly Replacing Text With Images

DZone's Guide to

Accessibly Replacing Text With Images

·
Free Resource
// There are quite a few methods to do this but here's one I used recently. It replaces the word "Correct" at the end of a sentence with a graphic tick.

HTML


This part of the text is displayed Correct

CSS span.correct {background:url(tick.gif); margin-left:0.5em; text-indent:21px; position:absolute; overflow:hidden; width:20px; height:19px}
Topics:

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}