Specify that some elements should not be translated:
The translate attribute specifies whether the content of an element should be translated or not.
Test: Use the Google translate box (at the top of the page) to change to another language, and look what happens to the word "ice cream" below:
Here we use translate="no": ice cream.
Here we use class="notranslate": ice cream.
Tip: Use class="notranslate" instead.
Attribute | |||||
---|---|---|---|---|---|
translate | Not supported | Not supported | Not supported | Not supported | Not supported |
The translate attribute is new in HTML5.
Value | Description |
---|---|
yes | Specifies that the content of the element should be translated |
no | Specifies that the content of the element should not be translated |
HTML Tutorial: HTML Attributes