Thymeleaf Tutorials

thymeleaf

What is Thymeleaf? Thymeleaf is Java library and template engine that supports XML/XHTML/HTML5 template engines. It is very well suited for processing the XHTML and HTML5 documents in the web applications. Also it can process the XML documents while work as offline applications. This is a new template engine and adopted by many of the […]

How To Use Switch Statement (th:switch) In Thymeleaf Template?

thymeleaf

In my previous articles I have explained about the hello world example and the expression language. This tutorial explains how to use the switch statements inside Thymeleaf template. Thymeleaf provides th:switch attribute for using switch functionality. This feature is extension of my previous example on iteration in thymeleaf template. 1. Set Up Thymeleaf Application To […]

How To Use th:each For Iteration In Thymeleaf Template?

thymeleaf

In my previous articles I have explained about the hello world example and the expression language. This tutorial explains how to iterate the list of values from an object. For Iteration In Thymeleaf Template, it provides th:each attribue for using inside a table element to iterate over the list of objects and display the list. This […]

How To Set Attributes in Thymeleaf Template using th:attr?

thymeleaf

In my previous articles I have explained about the hello world example and the expression language. This tutorial explains how to set the attribute to the template at the time of processing. This feature is very useful for creating the templates. Thymeleaf provides very easy syntax for just adding the attributes dynamically from the properties […]

org.thymeleaf.exceptions.TemplateProcessingException: Exception evaluating OGNL expression

thymeleaf

When you work with Thymeleaf application, you would have encountered the TemplateProcessingException exceptions. The problem is the use of default context variables. It could be because of Wrong use of the context variable name (or) The property name accessed by the context variable object is not correct.

Context Objects in Thymeleaf

thymeleaf

In my previous article I have explained about the different types of expression languages used in Thymeleaf framework. If you have worked with JSP or any other web frameworks, there are number of implicit objects available in the context for the free use. These objects are created by the container and made it available with […]

Expression Language in Thymeleaf

thymeleaf

In my previous tutorial I have explained about the simple hello world example to start writing your first example using the Thymeleaf framework. If you are not familiar with this new framework, I would recommend to read that tutorial before start reading this tutorial. When we work with web frameworks, one of the important feature […]

WebContext in Thymeleaf

thymeleaf

In my previous tutorial I have explained about writing your first Hello World example using Thymeleaf template engine framework. If you look at the example, it uses some kind of context to transfer the variables across its application. The same way how ServletContext or SpringApplicationContext works, Thymeleaf has its own context framework to maintain its […]

Thymeleaf Hello World Example

thymeleaf

This tutorial is Hello World example for the template engine framework Thymeleaf. This framework is released few years back and many projects adopted this template engine framework. In simple terms, Thymeleaf is a Java library which can be easily integrated to any Java applications or frameworks like Spring to use as the view templates. Thymeleaf […]

Close
Please support the site
By clicking any of these buttons you help our site to get better