SlideShare a Scribd company logo
1 of 40
Download to read offline
A11Y? I18N? L10N? UTF8? WTF?
Understanding the
connections between:
accessibility,
internationalization,
localization,
and character sets
Michael Toppa
@mtoppa
WordCamp Nashville
May 3, 2014
About meā€¦
* Iā€™ve been developing for the web since the days of HTML 1.0, when web pages were ļ¬rst painted on cave walls.
* This is my 7th WordCamp presentation, and I have 7 plugins at wordpress.org, dating back to 2006.
* I was previously the Director of Development for WebDevStudios. One of my assignments while there was managing the WordPress VIP project for NBC
Latino.
* Iā€™ve also managed the 16 person web application team at the U Penn School of Medicine, and I previously worked at Stanford, Georgetown, Ask
Jeeves, and E-Trade.
Iā€™m now working at PromptWorks, a small consultancy in Philadelphia. We do a lot of work in Ruby, Rails, JavaScript, and infrastructure automation. In
addition to building products for our clients, we work closely with them, and pair program with them when possible. So that when we leave, they can
continue on the path using TDD and good object oriented design.
Accessibility, internationalization, and character sets are normally presented as separate, distinct topics. But I see them as strongly interconnected, and so
in this talk Iā€™m going to discuss all of them, with a focus on how they relate to each other. This talk is by no means comprehensive, as they are each big
topics. My goal is start you thinking about how to make your web content more accessible to people with varying levels of ability using the web, and who
speak different languages.
Accessibility (A11Y)
Red, yellow, and green all look yellowish to many color-blind people. So how do they understand street signal lights?
They pay attention to the order instead. The signal lights communicate in two ways.
Accessibility (A11Y)
Like the signal lights, this wheel chair ramp is a good example of incorporating accessibility into a design without it making things ugly or seeming like an
afterthought.
Why bother?
Before going any further, why should you spend time worrying about any of this? If youā€™re just making a web site for a small business here in Nashville, why
spend time coding for accessibility, or worrying about languages other than English?
Reason #1
Accessibility ā‰  Disability
Accessibility is important for a wide variety of people:
* older people, who often have impaired hearing, difļ¬culty clicking on small targets, etc
* people with low literacy or not ļ¬‚uent in the language
* people with low bandwidth connections or using older technologies
* new and infrequent users
* ā€¦and persons with disabilities
Reason #2
More people need help than you think
* More than half of Americans over 65 are now online, and they spend a lot of time online
* About 9% of men suffer from a type of color blindness
* The number of Americans who speak a language other than English at home has tripled since 1980, to 1 in 5 Americans. Thatā€™s about 60 million people.
* About 5% of Americans donā€™t speak English ļ¬‚uently, thatā€™s over 15 million people.
* Another 5% live in places where the only way to get online is through slow dial-up connections.
* And thatā€™s just the USā€¦
Reason #3
The cost is low
As we go along in this talk, youā€™ll see that meeting basic accessibility needs is not that hard. Itā€™s also not hard to set up your content to be translation
ready, even if you donā€™t need to support other languages right now.
Reason #4
Itā€™s the right thing to do
When you donā€™t give any thought to how people with varying abilities can use your site, the result can be a miserable experience for them.
Things I learned by pretending to be blind for a week
Some well known sites, such as Facebook and Amazon, are almost unusable by blind people. The Amazon home page has over 1,000 links, few alt tags for
images, and few ARIA landmarks (ā€œroleā€ attributes), which help screen readers identify different regions of a page.
WCAG Accessibility Guidelines
1. Perceivable
<img src="smiley.gif" alt="Smiley face">
2. Operable
<input accesskey="S" type="submit" value="Submit">
3. Understandable and Predictable
<a href="news.html" target=ā€œ_blankā€>latest news (opens new
window)</a>
4. Robust and Compatible
<label for="ļ¬rst_name">First Name</label>
The World Wide Web Consortium (W3c) put together version 2 of their Web Content Accessibility Guidelines in 2008, and it has 4 key principles:
Perceivable - e.g. provide text alternatives for non-textual content
Operable - e.g make all functionality available from the keyboard, provide good site navigation
Understandable - e.g. help users avoid and prevent mistakes, such as clearly indicating errors in a form submission
Robust - e.g. use valid, well-structured HTML to maximize compatibility with user agents such as screen readers
WCAG Accessibility Guidelines
1. Perceivable
2. Operable
3. Understandable and Predictable
ā– Guideline 3.1.1 Language of Page:
ā– The default human language of each Web page can be
programmatically determined.
4. Robust and Compatible
There are 17 guidelines to follow for making a web page understandable. The ļ¬rst one is that it should be possible to programmatically determine the
language of a web page.
The lang attribute
ā– Declare the language of a WordPress theme in
header.php:
<html <?php language_attributes(); ?>>
For a US English site, this renders as:
<html lang="en-US">
ā– In HTML 5, declare the language of part of a document
<div lang="fr">
WordPress itself has been translated to over 70 languages, and if you are developing a theme or plugin, you need to make sure you are using the lang
attribute appropriately.
The language_attributes function will set a lang attribute based on the language speciļ¬ed in your wp-conļ¬g.php ļ¬le
Uses of the lang attribute
ā– Supports speech synthesizers and automated translators
ā– Supports spelling and grammar checkers
ā– Improves search engine results
ā– Helps support server content negotiation
ā– Allows user-agents to select language appropriate fonts
Content negotiation lets the browser tell the server what media types and languages it prefers, and the server will do its best to comply. There is a plugin
to support this in WordPress.
Language appropriate fonts
This ideographic character has the same Unicode value and meaning in Chinese, Japanese, and Korean. The character means ā€œsnow.ā€ But it is rendered
differently, depending on whether the lang attribute of the page is set to Simpliļ¬ed Chinese, Traditional Chinese, Japanese, or Korean.
Unicode?
Unicode is a single character set designed to include characters from just about every writing system on the planet. This is a small section of the Unicode
character map, showing characters used in languages spoken in Myanmar.
Klingon for
Unicode
It supports languages from off the planet as well. Although the Klingon application for incorporation into Unicode was rejected in 2001, encoding for it
was created it whatā€™s called the ā€œprivate useā€ range of code points in Unicode. So there are web sites out there written in Klingon, and you can download
Klingon fonts so you can read them.
Solving the
Unicode
Puzzle:
PHP
Architect,
May 2005
In 2005 I wrote an article on conļ¬guring Apache, Oracle, and PHP for Unicode, published in PHP Architect. At that time Unicode was just emerging as the
new standard for character encoding, and conļ¬guring end-to-end support for using it in web applications was a signiļ¬cant undertaking. These days,
Unicode support comes out of the box for the most part.
Before there was Unicodeā€¦
Lower ASCII
Unicode has been prevalent on the web for about 10 years now. In the 1960s, unaccented English characters, as well as various control characters for
carriage returns, page feeds, etc., were each assigned a number from 0 to 127; there was general agreement on these number assignments, and so ASCII
was born (American Standard Code for Information Interchange).
Before there was Unicodeā€¦
Upper ASCII: ISO 8859-1 (aka Latin 1)
The ASCII characters could ļ¬t in 7 bits, and computers used 8-bit bytes, which left an extra bit of space. This led to the proliferation of many different
character sets, with each one using this extra space in a different way. Hereā€™s Latin 1, which contains special symbols and accented characters for Western
languages.
Before there was Unicodeā€¦
Upper ASCII: ISO 8859-2
Hereā€™s the version of Upper ASCII that supports Slavic languages. There are 15 variations on this ISO standard. This means that text generated on, say, a
computer in Russia would turn into gibberish if you tried to read it on a computer in the US. This happened because the number codes representing the
Cyrillic characters were assigned to totally different characters on the US computer. This became a bit of a problem when everyone started using the
internet.
The Unicode slogan
ā€œUnicode provides a unique number for every
character, no matter what the platform, no
matter what the program, no matter what the
language.ā€
Unicode represents an effort to clean up this mess. Unicode can do this because it allows characters to occupy more than one byte, so it has enough room
to store characters from languages around the worldā€”even Asian languages that have thousands of characters. Itā€™s a character set able to support over 1
million characters.
So what is UTF-8?
Unicode is a character set, and there are 3 different ways to encode it. UTF-8 is the unicode encoding standard for the web because, like ASCII, itā€™s an 8-
bit encoding, and itā€™s compatible with the Latin1 ASCII character set. This makes it backwards compatible with most previously created Western language
documents.
Learning everyday Japanese with Mangajin
UTF-8 is the standard character encoding in WordPress, since version 2.2. Hereā€™s an example from my blog, showing a multi-lingual post.
WordPress supports UTF-8
Localization (L10N) and
Internationalization (I18N)
A multi-lingual page like that is fairly uncommon. More commonly, content is created in one language, but we want a standardized way to enable the
creation of translations into other languages. This is where localization and internationalization come in.
Localization
ā€œLocalization refers to the adaptation of
a product, application or document
content to meet the language, cultural
and other requirements of a speciļ¬c
target market (a locale).ā€
This often involves more than just translation
In addition to translation, this can also involve dealing with variations in numeric, date, currency, and time formats, varying legal requirements, and
awareness of things that may be misunderstood or be offensive in other cultures.
Internationalization
ā€œInternationalization is the design and
development of a product, application or
document content that enables easy
localization for target audiences that
vary in culture, region, or language.ā€
WordPress provides internationalization
features so you can localize your themes and
plugins
Step 1: use WordPressā€™ I18N functions
ā– Wrap all your text in WordPressā€™ I18N functions, using a
custom ā€œtext domainā€. This is for my ā€œshashinā€ plugin:
ā– $greeting = __( 'Howdy', 'shashin' );
ā– <li><?php _e( 'Howdy', 'shashin' ); ?></li>
ā– $string = _x( 'Buffalo', 'an animal', 'shashin' );
ā– $string = _x( 'Buffalo', 'a city in New York', 'shashin' );
ā– And othersā€¦
Step 2: load your text domain
ā– For plugins:
load_plugin_textdomain(
'shashin',
false,
dirname(plugin_basename(__FILE__)) . '/languages/'
);
Give it the path to translation ļ¬les, which we will create in the next steps
Step 2: load your text domain
ā– For themes:
function custom_theme_setup() {
load_theme_textdomain(
'my_theme',
get_template_directory() . '/languages')
);
}
add_action('after_setup_theme', 'custom_theme_setup');
Step 3: generate a POT file
The POT ļ¬le serves as a template for translating your theme or plugin into other languages. It extracts all the text you wrapped in the WordPressā€™ I18N
functions and puts them in a single ļ¬le. If you have a plugin in the wordpress.org repository, it can generate a POT ļ¬le for you. There are other tools
available for this as well. See the references at the end of this talk for other ways to generate a POT ļ¬le for themes and plugins
Step 4: create translation files
This is a screenshot from POEdit. With POEdit, a translator can take your POT ļ¬le and create a translation to another language. This translation creates a
textual .po ļ¬le, and then a binary, compiled version of it, in a .mo ļ¬le. If you include a .mo ļ¬le translation that matches the language conļ¬guration of a
WordPress site, your theme or plugin can be shown in that language.
If you include the .pot ļ¬le with your theme or plugin, and it becomes popular, youā€™ll probably start receiving unsolicited translations from people who have
translated for us in their language, and want to share the translation for others to use.
Step 4: create translation files
ā– Other translation options:
ā– The Codestyling Localization plugin
ā– For themes, the ThemeZee translation site
The Codestyling localization plugin creates ļ¬les compatible with POEdit, and works directly with the Google Translate API and Microsoft Translator API to
help you translate. It has not been updated in over a year though.
ThemeZee has a collaborative online theme translation community, which you can join for free
Step 5: include translation files
This shows all the different language translations available for the popular plugin, Contact Form 7.
Maintaining translations can be difļ¬cult, as you will usually need to get an updated translation for each new release of your plugin or theme. Even just
changes in line numbers can throw off the translation.
Questions?
Further reading
ā– W3C
ā– How to meet WCAG 2.0: quick reference
ā– Why use the language attribute?
ā– Localization vs. Internationalization
ā– WordPress
ā– How To Localize WordPress Themes and Plugins
ā– I18n for WordPress Developers
ā– Internationalization: Youā€™re probably doing it wrong
ā– Solving the Unicode Puzzle

More Related Content

What's hot

O protocolo ftp (file transfer protocol)
O protocolo ftp (file transfer protocol)O protocolo ftp (file transfer protocol)
O protocolo ftp (file transfer protocol)ErikHR
Ā 
OCL: Object Constraint Language
OCL: Object Constraint LanguageOCL: Object Constraint Language
OCL: Object Constraint Languageelliando dias
Ā 
tmn - IntroduĆ§Ć£o ao JavaScript
tmn - IntroduĆ§Ć£o ao JavaScripttmn - IntroduĆ§Ć£o ao JavaScript
tmn - IntroduĆ§Ć£o ao JavaScriptClaudio Gamboa
Ā 
Paradigmas De Linguagem De ProgramaĆ§Ć£o.
Paradigmas De Linguagem De ProgramaĆ§Ć£o.Paradigmas De Linguagem De ProgramaĆ§Ć£o.
Paradigmas De Linguagem De ProgramaĆ§Ć£o.Valmon Gaudencio
Ā 
Cisco UCM Mobility Services
Cisco UCM Mobility ServicesCisco UCM Mobility Services
Cisco UCM Mobility ServicesCisco Russia
Ā 
Scaling tokopedia-past-present-future
Scaling tokopedia-past-present-futureScaling tokopedia-past-present-future
Scaling tokopedia-past-present-futureRein Mahatma
Ā 
Local Area Network Design of 1 Village & 2 Apartments for Internet Service
Local Area Network Design of 1 Village & 2 Apartments for Internet ServiceLocal Area Network Design of 1 Village & 2 Apartments for Internet Service
Local Area Network Design of 1 Village & 2 Apartments for Internet ServiceSubhajit Sahu
Ā 

What's hot (9)

O protocolo ftp (file transfer protocol)
O protocolo ftp (file transfer protocol)O protocolo ftp (file transfer protocol)
O protocolo ftp (file transfer protocol)
Ā 
What is a Private 5G Network.pdf
What is a Private 5G Network.pdfWhat is a Private 5G Network.pdf
What is a Private 5G Network.pdf
Ā 
OCL: Object Constraint Language
OCL: Object Constraint LanguageOCL: Object Constraint Language
OCL: Object Constraint Language
Ā 
tmn - IntroduĆ§Ć£o ao JavaScript
tmn - IntroduĆ§Ć£o ao JavaScripttmn - IntroduĆ§Ć£o ao JavaScript
tmn - IntroduĆ§Ć£o ao JavaScript
Ā 
Paradigmas De Linguagem De ProgramaĆ§Ć£o.
Paradigmas De Linguagem De ProgramaĆ§Ć£o.Paradigmas De Linguagem De ProgramaĆ§Ć£o.
Paradigmas De Linguagem De ProgramaĆ§Ć£o.
Ā 
Cisco UCM Mobility Services
Cisco UCM Mobility ServicesCisco UCM Mobility Services
Cisco UCM Mobility Services
Ā 
Scaling tokopedia-past-present-future
Scaling tokopedia-past-present-futureScaling tokopedia-past-present-future
Scaling tokopedia-past-present-future
Ā 
5G Technology
5G Technology5G Technology
5G Technology
Ā 
Local Area Network Design of 1 Village & 2 Apartments for Internet Service
Local Area Network Design of 1 Village & 2 Apartments for Internet ServiceLocal Area Network Design of 1 Village & 2 Apartments for Internet Service
Local Area Network Design of 1 Village & 2 Apartments for Internet Service
Ā 

Similar to A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessibility, internationalization, localization, and character sets (long version)

Java As A Programming Language
Java As A Programming LanguageJava As A Programming Language
Java As A Programming LanguageJennifer Wright
Ā 
Intro to web development
Intro to web developmentIntro to web development
Intro to web developmentMusTufa Nullwala
Ā 
10 tips for a usable website
10 tips for a usable website10 tips for a usable website
10 tips for a usable websiteBart De Waele
Ā 
Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...Carmen Sanborn
Ā 
LATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptx
LATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptxLATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptx
LATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptxchitrachauhan21
Ā 
Universal access across devices
Universal access across devicesUniversal access across devices
Universal access across devicesHenny Swan
Ā 
Top Backend Development Languages and Frameworks for Modern Web Applications
Top Backend Development Languages and Frameworks for Modern Web ApplicationsTop Backend Development Languages and Frameworks for Modern Web Applications
Top Backend Development Languages and Frameworks for Modern Web ApplicationsKaneJordy1
Ā 
What is the best programming language to learn if you want to work on the blo...
What is the best programming language to learn if you want to work on the blo...What is the best programming language to learn if you want to work on the blo...
What is the best programming language to learn if you want to work on the blo...BlockchainX
Ā 
How to choose a programming language 2.20.18 sd
How to choose a programming language   2.20.18 sdHow to choose a programming language   2.20.18 sd
How to choose a programming language 2.20.18 sdJordan Zurowski
Ā 
Website design2
Website design2Website design2
Website design2robclarkson
Ā 
Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...Neil Perlin
Ā 
Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...Neil Perlin
Ā 
Swift vs. Language X
Swift vs. Language XSwift vs. Language X
Swift vs. Language XScott Wlaschin
Ā 
15 Top reasons to choose Java for Backend Development
15 Top reasons to choose Java for Backend Development15 Top reasons to choose Java for Backend Development
15 Top reasons to choose Java for Backend DevelopmentYour Team in India
Ā 
corePHP Usability Accessibility by Steven Pignataro
corePHP Usability Accessibility by Steven PignatarocorePHP Usability Accessibility by Steven Pignataro
corePHP Usability Accessibility by Steven PignataroJohn Coonen
Ā 
Computer programminglanguages
Computer programminglanguagesComputer programminglanguages
Computer programminglanguagesPaulineGayVillarama
Ā 
Which programming language should you learn next?
Which programming language should you learn next? Which programming language should you learn next?
Which programming language should you learn next? Ganesh Samarthyam
Ā 
Proglangauage1.10.18
Proglangauage1.10.18Proglangauage1.10.18
Proglangauage1.10.18Thinkful
Ā 
The Guide to becoming a full stack developer in 2018
The Guide to becoming a full stack developer in 2018The Guide to becoming a full stack developer in 2018
The Guide to becoming a full stack developer in 2018Amit Ashwini
Ā 

Similar to A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessibility, internationalization, localization, and character sets (long version) (20)

Java As A Programming Language
Java As A Programming LanguageJava As A Programming Language
Java As A Programming Language
Ā 
Intro to web development
Intro to web developmentIntro to web development
Intro to web development
Ā 
10 tips for a usable website
10 tips for a usable website10 tips for a usable website
10 tips for a usable website
Ā 
Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...
Ā 
LATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptx
LATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptxLATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptx
LATEST_TRENDS_IN_WEBSITE_DEVELOPMENT.pptx
Ā 
Universal access across devices
Universal access across devicesUniversal access across devices
Universal access across devices
Ā 
Top Backend Development Languages and Frameworks for Modern Web Applications
Top Backend Development Languages and Frameworks for Modern Web ApplicationsTop Backend Development Languages and Frameworks for Modern Web Applications
Top Backend Development Languages and Frameworks for Modern Web Applications
Ā 
What is the best programming language to learn if you want to work on the blo...
What is the best programming language to learn if you want to work on the blo...What is the best programming language to learn if you want to work on the blo...
What is the best programming language to learn if you want to work on the blo...
Ā 
How to choose a programming language 2.20.18 sd
How to choose a programming language   2.20.18 sdHow to choose a programming language   2.20.18 sd
How to choose a programming language 2.20.18 sd
Ā 
Website design2
Website design2Website design2
Website design2
Ā 
Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...
Ā 
Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...Overcoming design challenges in hat based multichannel publishing - stc summi...
Overcoming design challenges in hat based multichannel publishing - stc summi...
Ā 
Swift vs. Language X
Swift vs. Language XSwift vs. Language X
Swift vs. Language X
Ā 
15 Top reasons to choose Java for Backend Development
15 Top reasons to choose Java for Backend Development15 Top reasons to choose Java for Backend Development
15 Top reasons to choose Java for Backend Development
Ā 
corePHP Usability Accessibility by Steven Pignataro
corePHP Usability Accessibility by Steven PignatarocorePHP Usability Accessibility by Steven Pignataro
corePHP Usability Accessibility by Steven Pignataro
Ā 
Computer programminglanguages
Computer programminglanguagesComputer programminglanguages
Computer programminglanguages
Ā 
Which programming language should you learn next?
Which programming language should you learn next? Which programming language should you learn next?
Which programming language should you learn next?
Ā 
Websites To Type Essays
Websites To Type EssaysWebsites To Type Essays
Websites To Type Essays
Ā 
Proglangauage1.10.18
Proglangauage1.10.18Proglangauage1.10.18
Proglangauage1.10.18
Ā 
The Guide to becoming a full stack developer in 2018
The Guide to becoming a full stack developer in 2018The Guide to becoming a full stack developer in 2018
The Guide to becoming a full stack developer in 2018
Ā 

More from mtoppa

RubyConf 2022 - From beginner to expert, and back again
RubyConf 2022 - From beginner to expert, and back againRubyConf 2022 - From beginner to expert, and back again
RubyConf 2022 - From beginner to expert, and back againmtoppa
Ā 
RailsConf 2022 - Upgrading Rails: The Dual Boot Way
RailsConf 2022 - Upgrading Rails: The Dual Boot WayRailsConf 2022 - Upgrading Rails: The Dual Boot Way
RailsConf 2022 - Upgrading Rails: The Dual Boot Waymtoppa
Ā 
Applying Omotenashi (Japanese customer service) to your work
Applying Omotenashi (Japanese customer service) to your workApplying Omotenashi (Japanese customer service) to your work
Applying Omotenashi (Japanese customer service) to your workmtoppa
Ā 
Talking to strangers causes train wrecks
Talking to strangers causes train wrecksTalking to strangers causes train wrecks
Talking to strangers causes train wrecksmtoppa
Ā 
The promise and peril of Agile and Lean practices
The promise and peril of Agile and Lean practicesThe promise and peril of Agile and Lean practices
The promise and peril of Agile and Lean practicesmtoppa
Ā 
Why do planes crash? Lessons for junior and senior developers
Why do planes crash? Lessons for junior and senior developersWhy do planes crash? Lessons for junior and senior developers
Why do planes crash? Lessons for junior and senior developersmtoppa
Ā 
Boston Ruby Meetup: The promise and peril of Agile and Lean practices
Boston Ruby Meetup: The promise and peril of Agile and Lean practicesBoston Ruby Meetup: The promise and peril of Agile and Lean practices
Boston Ruby Meetup: The promise and peril of Agile and Lean practicesmtoppa
Ā 
A real-life overview of Agile and Scrum
A real-life overview of Agile and ScrumA real-life overview of Agile and Scrum
A real-life overview of Agile and Scrummtoppa
Ā 
WordCamp Nashville 2016: The promise and peril of Agile and Lean practices
WordCamp Nashville 2016: The promise and peril of Agile and Lean practicesWordCamp Nashville 2016: The promise and peril of Agile and Lean practices
WordCamp Nashville 2016: The promise and peril of Agile and Lean practicesmtoppa
Ā 
WordCamp US: Clean Code
WordCamp US: Clean CodeWordCamp US: Clean Code
WordCamp US: Clean Codemtoppa
Ā 
Dependency Injection for PHP
Dependency Injection for PHPDependency Injection for PHP
Dependency Injection for PHPmtoppa
Ā 
WordCamp Boston 2015: Agile Contracts for WordPress Consultants
WordCamp Boston 2015: Agile Contracts for WordPress ConsultantsWordCamp Boston 2015: Agile Contracts for WordPress Consultants
WordCamp Boston 2015: Agile Contracts for WordPress Consultantsmtoppa
Ā 
WordCamp Nashville 2015: Agile Contracts for WordPress Consultants
WordCamp Nashville 2015: Agile Contracts for WordPress ConsultantsWordCamp Nashville 2015: Agile Contracts for WordPress Consultants
WordCamp Nashville 2015: Agile Contracts for WordPress Consultantsmtoppa
Ā 
Rails testing: factories or fixtures?
Rails testing: factories or fixtures?Rails testing: factories or fixtures?
Rails testing: factories or fixtures?mtoppa
Ā 
WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?
WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?
WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?mtoppa
Ā 
WordCamp Nashville: Clean Code for WordPress
WordCamp Nashville: Clean Code for WordPressWordCamp Nashville: Clean Code for WordPress
WordCamp Nashville: Clean Code for WordPressmtoppa
Ā 
A real-life overview of Agile workflow practices
A real-life overview of Agile workflow practicesA real-life overview of Agile workflow practices
A real-life overview of Agile workflow practicesmtoppa
Ā 
Why Agile? Why Now?
Why Agile? Why Now?Why Agile? Why Now?
Why Agile? Why Now?mtoppa
Ā 
Object Oriented Programming for WordPress Plugin Development
Object Oriented Programming for WordPress Plugin DevelopmentObject Oriented Programming for WordPress Plugin Development
Object Oriented Programming for WordPress Plugin Developmentmtoppa
Ā 
Dependency Injection for Wordpress
Dependency Injection for WordpressDependency Injection for Wordpress
Dependency Injection for Wordpressmtoppa
Ā 

More from mtoppa (20)

RubyConf 2022 - From beginner to expert, and back again
RubyConf 2022 - From beginner to expert, and back againRubyConf 2022 - From beginner to expert, and back again
RubyConf 2022 - From beginner to expert, and back again
Ā 
RailsConf 2022 - Upgrading Rails: The Dual Boot Way
RailsConf 2022 - Upgrading Rails: The Dual Boot WayRailsConf 2022 - Upgrading Rails: The Dual Boot Way
RailsConf 2022 - Upgrading Rails: The Dual Boot Way
Ā 
Applying Omotenashi (Japanese customer service) to your work
Applying Omotenashi (Japanese customer service) to your workApplying Omotenashi (Japanese customer service) to your work
Applying Omotenashi (Japanese customer service) to your work
Ā 
Talking to strangers causes train wrecks
Talking to strangers causes train wrecksTalking to strangers causes train wrecks
Talking to strangers causes train wrecks
Ā 
The promise and peril of Agile and Lean practices
The promise and peril of Agile and Lean practicesThe promise and peril of Agile and Lean practices
The promise and peril of Agile and Lean practices
Ā 
Why do planes crash? Lessons for junior and senior developers
Why do planes crash? Lessons for junior and senior developersWhy do planes crash? Lessons for junior and senior developers
Why do planes crash? Lessons for junior and senior developers
Ā 
Boston Ruby Meetup: The promise and peril of Agile and Lean practices
Boston Ruby Meetup: The promise and peril of Agile and Lean practicesBoston Ruby Meetup: The promise and peril of Agile and Lean practices
Boston Ruby Meetup: The promise and peril of Agile and Lean practices
Ā 
A real-life overview of Agile and Scrum
A real-life overview of Agile and ScrumA real-life overview of Agile and Scrum
A real-life overview of Agile and Scrum
Ā 
WordCamp Nashville 2016: The promise and peril of Agile and Lean practices
WordCamp Nashville 2016: The promise and peril of Agile and Lean practicesWordCamp Nashville 2016: The promise and peril of Agile and Lean practices
WordCamp Nashville 2016: The promise and peril of Agile and Lean practices
Ā 
WordCamp US: Clean Code
WordCamp US: Clean CodeWordCamp US: Clean Code
WordCamp US: Clean Code
Ā 
Dependency Injection for PHP
Dependency Injection for PHPDependency Injection for PHP
Dependency Injection for PHP
Ā 
WordCamp Boston 2015: Agile Contracts for WordPress Consultants
WordCamp Boston 2015: Agile Contracts for WordPress ConsultantsWordCamp Boston 2015: Agile Contracts for WordPress Consultants
WordCamp Boston 2015: Agile Contracts for WordPress Consultants
Ā 
WordCamp Nashville 2015: Agile Contracts for WordPress Consultants
WordCamp Nashville 2015: Agile Contracts for WordPress ConsultantsWordCamp Nashville 2015: Agile Contracts for WordPress Consultants
WordCamp Nashville 2015: Agile Contracts for WordPress Consultants
Ā 
Rails testing: factories or fixtures?
Rails testing: factories or fixtures?Rails testing: factories or fixtures?
Rails testing: factories or fixtures?
Ā 
WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?
WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?
WordCamp Lancaster 2014: A11Y? I18N? L10N? UTF8? WTF?
Ā 
WordCamp Nashville: Clean Code for WordPress
WordCamp Nashville: Clean Code for WordPressWordCamp Nashville: Clean Code for WordPress
WordCamp Nashville: Clean Code for WordPress
Ā 
A real-life overview of Agile workflow practices
A real-life overview of Agile workflow practicesA real-life overview of Agile workflow practices
A real-life overview of Agile workflow practices
Ā 
Why Agile? Why Now?
Why Agile? Why Now?Why Agile? Why Now?
Why Agile? Why Now?
Ā 
Object Oriented Programming for WordPress Plugin Development
Object Oriented Programming for WordPress Plugin DevelopmentObject Oriented Programming for WordPress Plugin Development
Object Oriented Programming for WordPress Plugin Development
Ā 
Dependency Injection for Wordpress
Dependency Injection for WordpressDependency Injection for Wordpress
Dependency Injection for Wordpress
Ā 

Recently uploaded

Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$
Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$
Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$kojalkojal131
Ā 
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girlsstephieert
Ā 
Russian Call Girls Thane Swara 8617697112 Independent Escort Service Thane
Russian Call Girls Thane Swara 8617697112 Independent Escort Service ThaneRussian Call Girls Thane Swara 8617697112 Independent Escort Service Thane
Russian Call Girls Thane Swara 8617697112 Independent Escort Service ThaneCall girls in Ahmedabad High profile
Ā 
Gram Darshan PPT cyber rural in villages of india
Gram Darshan PPT cyber rural  in villages of indiaGram Darshan PPT cyber rural  in villages of india
Gram Darshan PPT cyber rural in villages of indiaimessage0108
Ā 
Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”soniya singh
Ā 
Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”soniya singh
Ā 
Russian Call Girls in Kolkata Ishita šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita šŸ¤Œ  8250192130 šŸš€ Vip Call Girls KolkataRussian Call Girls in Kolkata Ishita šŸ¤Œ  8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkataanamikaraghav4
Ā 
Challengers I Told Ya ShirtChallengers I Told Ya Shirt
Challengers I Told Ya ShirtChallengers I Told Ya ShirtChallengers I Told Ya ShirtChallengers I Told Ya Shirt
Challengers I Told Ya ShirtChallengers I Told Ya Shirtrahman018755
Ā 
Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012
Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012
Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012rehmti665
Ā 
Low Rate Call Girls Kolkata Avani šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani šŸ¤Œ  8250192130 šŸš€ Vip Call Girls KolkataLow Rate Call Girls Kolkata Avani šŸ¤Œ  8250192130 šŸš€ Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkataanamikaraghav4
Ā 
VIP Kolkata Call Girls Salt Lake 8250192130 Available With Room
VIP Kolkata Call Girls Salt Lake 8250192130 Available With RoomVIP Kolkata Call Girls Salt Lake 8250192130 Available With Room
VIP Kolkata Call Girls Salt Lake 8250192130 Available With Roomgirls4nights
Ā 
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...APNIC
Ā 
Russian Call Girls in Kolkata Samaira šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira šŸ¤Œ  8250192130 šŸš€ Vip Call Girls KolkataRussian Call Girls in Kolkata Samaira šŸ¤Œ  8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkataanamikaraghav4
Ā 
Networking in the Penumbra presented by Geoff Huston at NZNOG
Networking in the Penumbra presented by Geoff Huston at NZNOGNetworking in the Penumbra presented by Geoff Huston at NZNOG
Networking in the Penumbra presented by Geoff Huston at NZNOGAPNIC
Ā 
AlbaniaDreamin24 - How to easily use an API with Flows
AlbaniaDreamin24 - How to easily use an API with FlowsAlbaniaDreamin24 - How to easily use an API with Flows
AlbaniaDreamin24 - How to easily use an API with FlowsThierry TROUIN ā˜
Ā 
Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...Sheetaleventcompany
Ā 
Russian Call girls in Dubai +971563133746 Dubai Call girls
Russian  Call girls in Dubai +971563133746 Dubai  Call girlsRussian  Call girls in Dubai +971563133746 Dubai  Call girls
Russian Call girls in Dubai +971563133746 Dubai Call girlsstephieert
Ā 

Recently uploaded (20)

Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$
Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$
Call Girls Dubai Prolapsed O525547819 Call Girls In Dubai Princes$
Ā 
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
Ā 
Russian Call Girls Thane Swara 8617697112 Independent Escort Service Thane
Russian Call Girls Thane Swara 8617697112 Independent Escort Service ThaneRussian Call Girls Thane Swara 8617697112 Independent Escort Service Thane
Russian Call Girls Thane Swara 8617697112 Independent Escort Service Thane
Ā 
Gram Darshan PPT cyber rural in villages of india
Gram Darshan PPT cyber rural  in villages of indiaGram Darshan PPT cyber rural  in villages of india
Gram Darshan PPT cyber rural in villages of india
Ā 
Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls In Defence Colony Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Ā 
Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Call Girls in Uttam Nagar Delhi šŸ’ÆCall Us šŸ”8264348440šŸ”
Ā 
Rohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No AdvanceRohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 6 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Ā 
Russian Call Girls in Kolkata Ishita šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita šŸ¤Œ  8250192130 šŸš€ Vip Call Girls KolkataRussian Call Girls in Kolkata Ishita šŸ¤Œ  8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Ā 
Rohini Sector 26 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 26 Call Girls Delhi 9999965857 @Sabina Saikh No AdvanceRohini Sector 26 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 26 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Ā 
Dwarka Sector 26 Call Girls | Delhi | 9999965857 šŸ«¦ Vanshika Verma More Our Se...
Dwarka Sector 26 Call Girls | Delhi | 9999965857 šŸ«¦ Vanshika Verma More Our Se...Dwarka Sector 26 Call Girls | Delhi | 9999965857 šŸ«¦ Vanshika Verma More Our Se...
Dwarka Sector 26 Call Girls | Delhi | 9999965857 šŸ«¦ Vanshika Verma More Our Se...
Ā 
Challengers I Told Ya ShirtChallengers I Told Ya Shirt
Challengers I Told Ya ShirtChallengers I Told Ya ShirtChallengers I Told Ya ShirtChallengers I Told Ya Shirt
Challengers I Told Ya ShirtChallengers I Told Ya Shirt
Ā 
Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012
Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012
Call Girls South Delhi Delhi reach out to us at ā˜Ž 9711199012
Ā 
Low Rate Call Girls Kolkata Avani šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani šŸ¤Œ  8250192130 šŸš€ Vip Call Girls KolkataLow Rate Call Girls Kolkata Avani šŸ¤Œ  8250192130 šŸš€ Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Ā 
VIP Kolkata Call Girls Salt Lake 8250192130 Available With Room
VIP Kolkata Call Girls Salt Lake 8250192130 Available With RoomVIP Kolkata Call Girls Salt Lake 8250192130 Available With Room
VIP Kolkata Call Girls Salt Lake 8250192130 Available With Room
Ā 
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
'Future Evolution of the Internet' delivered by Geoff Huston at Everything Op...
Ā 
Russian Call Girls in Kolkata Samaira šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira šŸ¤Œ  8250192130 šŸš€ Vip Call Girls KolkataRussian Call Girls in Kolkata Samaira šŸ¤Œ  8250192130 šŸš€ Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira šŸ¤Œ 8250192130 šŸš€ Vip Call Girls Kolkata
Ā 
Networking in the Penumbra presented by Geoff Huston at NZNOG
Networking in the Penumbra presented by Geoff Huston at NZNOGNetworking in the Penumbra presented by Geoff Huston at NZNOG
Networking in the Penumbra presented by Geoff Huston at NZNOG
Ā 
AlbaniaDreamin24 - How to easily use an API with Flows
AlbaniaDreamin24 - How to easily use an API with FlowsAlbaniaDreamin24 - How to easily use an API with Flows
AlbaniaDreamin24 - How to easily use an API with Flows
Ā 
Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...
Call Girls Service Chandigarh Lucky ā¤ļø 7710465962 Independent Call Girls In C...
Ā 
Russian Call girls in Dubai +971563133746 Dubai Call girls
Russian  Call girls in Dubai +971563133746 Dubai  Call girlsRussian  Call girls in Dubai +971563133746 Dubai  Call girls
Russian Call girls in Dubai +971563133746 Dubai Call girls
Ā 

A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessibility, internationalization, localization, and character sets (long version)

  • 1. A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessibility, internationalization, localization, and character sets Michael Toppa @mtoppa WordCamp Nashville May 3, 2014
  • 2. About meā€¦ * Iā€™ve been developing for the web since the days of HTML 1.0, when web pages were ļ¬rst painted on cave walls. * This is my 7th WordCamp presentation, and I have 7 plugins at wordpress.org, dating back to 2006. * I was previously the Director of Development for WebDevStudios. One of my assignments while there was managing the WordPress VIP project for NBC Latino. * Iā€™ve also managed the 16 person web application team at the U Penn School of Medicine, and I previously worked at Stanford, Georgetown, Ask Jeeves, and E-Trade.
  • 3. Iā€™m now working at PromptWorks, a small consultancy in Philadelphia. We do a lot of work in Ruby, Rails, JavaScript, and infrastructure automation. In addition to building products for our clients, we work closely with them, and pair program with them when possible. So that when we leave, they can continue on the path using TDD and good object oriented design.
  • 4. Accessibility, internationalization, and character sets are normally presented as separate, distinct topics. But I see them as strongly interconnected, and so in this talk Iā€™m going to discuss all of them, with a focus on how they relate to each other. This talk is by no means comprehensive, as they are each big topics. My goal is start you thinking about how to make your web content more accessible to people with varying levels of ability using the web, and who speak different languages.
  • 5. Accessibility (A11Y) Red, yellow, and green all look yellowish to many color-blind people. So how do they understand street signal lights? They pay attention to the order instead. The signal lights communicate in two ways.
  • 6. Accessibility (A11Y) Like the signal lights, this wheel chair ramp is a good example of incorporating accessibility into a design without it making things ugly or seeming like an afterthought.
  • 7. Why bother? Before going any further, why should you spend time worrying about any of this? If youā€™re just making a web site for a small business here in Nashville, why spend time coding for accessibility, or worrying about languages other than English?
  • 8. Reason #1 Accessibility ā‰  Disability Accessibility is important for a wide variety of people: * older people, who often have impaired hearing, difļ¬culty clicking on small targets, etc * people with low literacy or not ļ¬‚uent in the language * people with low bandwidth connections or using older technologies * new and infrequent users * ā€¦and persons with disabilities
  • 9. Reason #2 More people need help than you think * More than half of Americans over 65 are now online, and they spend a lot of time online * About 9% of men suffer from a type of color blindness * The number of Americans who speak a language other than English at home has tripled since 1980, to 1 in 5 Americans. Thatā€™s about 60 million people. * About 5% of Americans donā€™t speak English ļ¬‚uently, thatā€™s over 15 million people. * Another 5% live in places where the only way to get online is through slow dial-up connections. * And thatā€™s just the USā€¦
  • 10. Reason #3 The cost is low As we go along in this talk, youā€™ll see that meeting basic accessibility needs is not that hard. Itā€™s also not hard to set up your content to be translation ready, even if you donā€™t need to support other languages right now.
  • 11. Reason #4 Itā€™s the right thing to do When you donā€™t give any thought to how people with varying abilities can use your site, the result can be a miserable experience for them.
  • 12. Things I learned by pretending to be blind for a week Some well known sites, such as Facebook and Amazon, are almost unusable by blind people. The Amazon home page has over 1,000 links, few alt tags for images, and few ARIA landmarks (ā€œroleā€ attributes), which help screen readers identify different regions of a page.
  • 13. WCAG Accessibility Guidelines 1. Perceivable <img src="smiley.gif" alt="Smiley face"> 2. Operable <input accesskey="S" type="submit" value="Submit"> 3. Understandable and Predictable <a href="news.html" target=ā€œ_blankā€>latest news (opens new window)</a> 4. Robust and Compatible <label for="ļ¬rst_name">First Name</label> The World Wide Web Consortium (W3c) put together version 2 of their Web Content Accessibility Guidelines in 2008, and it has 4 key principles: Perceivable - e.g. provide text alternatives for non-textual content Operable - e.g make all functionality available from the keyboard, provide good site navigation Understandable - e.g. help users avoid and prevent mistakes, such as clearly indicating errors in a form submission Robust - e.g. use valid, well-structured HTML to maximize compatibility with user agents such as screen readers
  • 14. WCAG Accessibility Guidelines 1. Perceivable 2. Operable 3. Understandable and Predictable ā– Guideline 3.1.1 Language of Page: ā– The default human language of each Web page can be programmatically determined. 4. Robust and Compatible There are 17 guidelines to follow for making a web page understandable. The ļ¬rst one is that it should be possible to programmatically determine the language of a web page.
  • 15. The lang attribute ā– Declare the language of a WordPress theme in header.php: <html <?php language_attributes(); ?>> For a US English site, this renders as: <html lang="en-US"> ā– In HTML 5, declare the language of part of a document <div lang="fr"> WordPress itself has been translated to over 70 languages, and if you are developing a theme or plugin, you need to make sure you are using the lang attribute appropriately. The language_attributes function will set a lang attribute based on the language speciļ¬ed in your wp-conļ¬g.php ļ¬le
  • 16. Uses of the lang attribute ā– Supports speech synthesizers and automated translators ā– Supports spelling and grammar checkers ā– Improves search engine results ā– Helps support server content negotiation ā– Allows user-agents to select language appropriate fonts Content negotiation lets the browser tell the server what media types and languages it prefers, and the server will do its best to comply. There is a plugin to support this in WordPress.
  • 17. Language appropriate fonts This ideographic character has the same Unicode value and meaning in Chinese, Japanese, and Korean. The character means ā€œsnow.ā€ But it is rendered differently, depending on whether the lang attribute of the page is set to Simpliļ¬ed Chinese, Traditional Chinese, Japanese, or Korean.
  • 18. Unicode? Unicode is a single character set designed to include characters from just about every writing system on the planet. This is a small section of the Unicode character map, showing characters used in languages spoken in Myanmar.
  • 19. Klingon for Unicode It supports languages from off the planet as well. Although the Klingon application for incorporation into Unicode was rejected in 2001, encoding for it was created it whatā€™s called the ā€œprivate useā€ range of code points in Unicode. So there are web sites out there written in Klingon, and you can download Klingon fonts so you can read them.
  • 20. Solving the Unicode Puzzle: PHP Architect, May 2005 In 2005 I wrote an article on conļ¬guring Apache, Oracle, and PHP for Unicode, published in PHP Architect. At that time Unicode was just emerging as the new standard for character encoding, and conļ¬guring end-to-end support for using it in web applications was a signiļ¬cant undertaking. These days, Unicode support comes out of the box for the most part.
  • 21. Before there was Unicodeā€¦ Lower ASCII Unicode has been prevalent on the web for about 10 years now. In the 1960s, unaccented English characters, as well as various control characters for carriage returns, page feeds, etc., were each assigned a number from 0 to 127; there was general agreement on these number assignments, and so ASCII was born (American Standard Code for Information Interchange).
  • 22. Before there was Unicodeā€¦ Upper ASCII: ISO 8859-1 (aka Latin 1) The ASCII characters could ļ¬t in 7 bits, and computers used 8-bit bytes, which left an extra bit of space. This led to the proliferation of many different character sets, with each one using this extra space in a different way. Hereā€™s Latin 1, which contains special symbols and accented characters for Western languages.
  • 23. Before there was Unicodeā€¦ Upper ASCII: ISO 8859-2 Hereā€™s the version of Upper ASCII that supports Slavic languages. There are 15 variations on this ISO standard. This means that text generated on, say, a computer in Russia would turn into gibberish if you tried to read it on a computer in the US. This happened because the number codes representing the Cyrillic characters were assigned to totally different characters on the US computer. This became a bit of a problem when everyone started using the internet.
  • 24. The Unicode slogan ā€œUnicode provides a unique number for every character, no matter what the platform, no matter what the program, no matter what the language.ā€ Unicode represents an effort to clean up this mess. Unicode can do this because it allows characters to occupy more than one byte, so it has enough room to store characters from languages around the worldā€”even Asian languages that have thousands of characters. Itā€™s a character set able to support over 1 million characters.
  • 25. So what is UTF-8? Unicode is a character set, and there are 3 different ways to encode it. UTF-8 is the unicode encoding standard for the web because, like ASCII, itā€™s an 8- bit encoding, and itā€™s compatible with the Latin1 ASCII character set. This makes it backwards compatible with most previously created Western language documents.
  • 26. Learning everyday Japanese with Mangajin UTF-8 is the standard character encoding in WordPress, since version 2.2. Hereā€™s an example from my blog, showing a multi-lingual post.
  • 28. Localization (L10N) and Internationalization (I18N) A multi-lingual page like that is fairly uncommon. More commonly, content is created in one language, but we want a standardized way to enable the creation of translations into other languages. This is where localization and internationalization come in.
  • 29. Localization ā€œLocalization refers to the adaptation of a product, application or document content to meet the language, cultural and other requirements of a speciļ¬c target market (a locale).ā€ This often involves more than just translation In addition to translation, this can also involve dealing with variations in numeric, date, currency, and time formats, varying legal requirements, and awareness of things that may be misunderstood or be offensive in other cultures.
  • 30. Internationalization ā€œInternationalization is the design and development of a product, application or document content that enables easy localization for target audiences that vary in culture, region, or language.ā€
  • 31. WordPress provides internationalization features so you can localize your themes and plugins
  • 32. Step 1: use WordPressā€™ I18N functions ā– Wrap all your text in WordPressā€™ I18N functions, using a custom ā€œtext domainā€. This is for my ā€œshashinā€ plugin: ā– $greeting = __( 'Howdy', 'shashin' ); ā– <li><?php _e( 'Howdy', 'shashin' ); ?></li> ā– $string = _x( 'Buffalo', 'an animal', 'shashin' ); ā– $string = _x( 'Buffalo', 'a city in New York', 'shashin' ); ā– And othersā€¦
  • 33. Step 2: load your text domain ā– For plugins: load_plugin_textdomain( 'shashin', false, dirname(plugin_basename(__FILE__)) . '/languages/' ); Give it the path to translation ļ¬les, which we will create in the next steps
  • 34. Step 2: load your text domain ā– For themes: function custom_theme_setup() { load_theme_textdomain( 'my_theme', get_template_directory() . '/languages') ); } add_action('after_setup_theme', 'custom_theme_setup');
  • 35. Step 3: generate a POT file The POT ļ¬le serves as a template for translating your theme or plugin into other languages. It extracts all the text you wrapped in the WordPressā€™ I18N functions and puts them in a single ļ¬le. If you have a plugin in the wordpress.org repository, it can generate a POT ļ¬le for you. There are other tools available for this as well. See the references at the end of this talk for other ways to generate a POT ļ¬le for themes and plugins
  • 36. Step 4: create translation files This is a screenshot from POEdit. With POEdit, a translator can take your POT ļ¬le and create a translation to another language. This translation creates a textual .po ļ¬le, and then a binary, compiled version of it, in a .mo ļ¬le. If you include a .mo ļ¬le translation that matches the language conļ¬guration of a WordPress site, your theme or plugin can be shown in that language. If you include the .pot ļ¬le with your theme or plugin, and it becomes popular, youā€™ll probably start receiving unsolicited translations from people who have translated for us in their language, and want to share the translation for others to use.
  • 37. Step 4: create translation files ā– Other translation options: ā– The Codestyling Localization plugin ā– For themes, the ThemeZee translation site The Codestyling localization plugin creates ļ¬les compatible with POEdit, and works directly with the Google Translate API and Microsoft Translator API to help you translate. It has not been updated in over a year though. ThemeZee has a collaborative online theme translation community, which you can join for free
  • 38. Step 5: include translation files This shows all the different language translations available for the popular plugin, Contact Form 7. Maintaining translations can be difļ¬cult, as you will usually need to get an updated translation for each new release of your plugin or theme. Even just changes in line numbers can throw off the translation.
  • 40. Further reading ā– W3C ā– How to meet WCAG 2.0: quick reference ā– Why use the language attribute? ā– Localization vs. Internationalization ā– WordPress ā– How To Localize WordPress Themes and Plugins ā– I18n for WordPress Developers ā– Internationalization: Youā€™re probably doing it wrong ā– Solving the Unicode Puzzle