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 trialJeremy Yi
9,512 PointsWhat is 'th' here?
I dont understand the meaning for 'th' here. Could anyone tell me more about it?
2 Answers
Jeremy Yi
9,512 Pointsthank you
Tony Martin
5,570 PointsAs a side note for anyone else with this question:
Doron has it right, however, I wanna add a piece of extra info. You could actually turn the 'th' into anything you want when you declare the namespace. For instance, using:
<html xmlns:SOMETHINGELSE="http://www.thymeleaf.org">
in your namespace declaration would replace the use of 'th' with 'SOMETHINGELSE'
okilydokily
12,105 PointsOk but why are we using a url for thymeleaf.org if this is just a namespace?
Doron Zehavi
Courses Plus Student 1,616 PointsDoron Zehavi
Courses Plus Student 1,616 PointsIt is an attribute of the namespace for Thymeleaf. You specified a namespace using xmlns which enables using attributes from the specified namespace. Then you use the th attribute to let Thymeleaf know about the href you want it to process.