how to print current date in JSP. I am using <%= new java.util.Date() %>, but I want to print date in the format like "October 01, 2008"

Posted on 2008-09-30
Medium Priority
Last Modified: 2013-11-24
Hi I want to print date in the JSP page using default java method. I am using <%= new java.util.Date() %>. but the format in which it is printing date includes current date and time with GMT time zone. But I want to print in a format like "October 01, 2008 ".  Can you please help me what code i need to write for this in JSP.
Question by:yashjimmy
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 23

Accepted Solution

Ajay-Singh earned 1500 total points
ID: 22611592
You can use this

<%= new java.text.SimpleDateFormat("MMMM dd, yyyy").format(new java.util.Date()) %>

Author Closing Comment

ID: 31501845

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
Suggested Courses

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question