Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialjohn knight
Courses Plus Student 9,155 PointsQuestion: when we use the attribute "lang" will it change the language of the text (Example Is Below).
EX. <p lang="fr">Hello World</p>
1 Answer
Steven Parker
231,236 PointsThe "lang" attribute is used to identify what language the content is in, it does not cause any action to occur. It might be used in a search to return only pages using a specified language.
The example shown above is not a valid use of the attribute! Here it as again along with a proper one:
<p lang="fr">Hello World</p> <!-- IMPROPER use of attribute (language mismatch) -->
<p lang="fr">Bonjour le Monde</p> <!-- correct use of attribute -->
john knight
Courses Plus Student 9,155 Pointsjohn knight
Courses Plus Student 9,155 PointsThank you , Steven
Steven Parker
231,236 PointsSteven Parker
231,236 PointsGlad to help. And happy coding!
john knight
Courses Plus Student 9,155 Pointsjohn knight
Courses Plus Student 9,155 PointsThank you again, Steven.