JavaBeat

  • Home
  • Java
    • Java 7
    • Java 8
    • Java EE
    • Servlets
  • Spring Framework
    • Spring Tutorials
    • Spring 4 Tutorials
    • Spring Boot
  • JSF Tutorials
  • Most Popular
    • Binary Search Tree Traversal
    • Spring Batch Tutorial
    • AngularJS + Spring MVC
    • Spring Data JPA Tutorial
    • Packaging and Deploying Node.js
  • About Us
    • Join Us (JBC)
  • Privacy
  • Contact Us

JSTL Formatting Tags Library

February 21, 2014 by Krishna Srinivasan Leave a Comment

The JSTL Formatting tag is used to format and parse the data that can be data element, date, time or number. This tag library is used in a jsp page. It also provides the support for internationalization.

Syntax – JSTL Formatting Tag

[code lang=”html”]
<%@ taglib uri= “http:// java.sun.com/jsp/jstl/fmt” prefix= “fmt” %>
[/code]

The JSTL Formatting Tags

  • <fmt: formatNumber>: The <fmt: formatNumber> tag is used to formatting the number data.
  • <fmt: parseNumber>: The <fmt: parseNumber> tag is used the parse the string of number data such as number, currency, or percentage.
  • <fmt: formatDate>: The <fmt: formatDate> tag is used to format the date and time.
  • <fmt: parseDate>: The <fmt: parseDate> tag allow us to parse the date and time.
  • <fmt: bundle>: The <fmt: bundle> tag is used to create a ResourceBundle object in its tag body.
  • <fmt: setLocale>: The setLocale is used to change the locale in the locale configuration variable.
  • <fmt: setBundle>: The setBundle tag is used to create a ResourceBundle and stores the object into the given variable.
  • <fmt: timeZone>: The <fmt: timeZone> tag is used to set the time zone.
  • <fmt: setTimeZone>: The <fmt:setTimeZone> tag is used to load the time zone into a specified scope variable.
  • <fmt: message>: The <fmt: message> tag maps key to localized message.
  • <fmt: requestEncoding>: The <fmt: requestEncoding> tag is used to set the character encoding of the request.

 

Previous Tutorial : JSTL Core c:url Tag  :: Next Tutorial : JSTL fmt:bundle

Filed Under: Java EE Tagged With: JSTL Tutorials

About Krishna Srinivasan

He is Founder and Chief Editor of JavaBeat. He has more than 8+ years of experience on developing Web applications. He writes about Spring, DOJO, JSF, Hibernate and many other emerging technologies in this blog.

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Follow Us

  • Facebook
  • Pinterest

As a participant in the Amazon Services LLC Associates Program, this site may earn from qualifying purchases. We may also earn commissions on purchases from other retail websites.

JavaBeat

FEATURED TUTORIALS

Answered: Using Java to Convert Int to String

What is new in Java 6.0 Collections API?

The Java 6.0 Compiler API

Copyright © by JavaBeat · All rights reserved