struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rod Bollinger" <techi...@portablegenius.com>
Subject RE: How to format util date with JSTL
Date Fri, 13 Apr 2007 20:04:13 GMT
Vinit,

Place the following at the top of your JSP:

<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>

Then, use the following to format your date:

<fmt:formatDate value="${myDateValue}" dateStyle="myDateStyleString" />

The dateStyle attribute uses the same semantics as the SimpleDateFormat. You
can alternatively use the pattern attribute to specify a custom date pattern
if you prefer.

HTH,
-Rod

-----Original Message-----
From: Vinit N [mailto:vinitnayak@hotmail.com] 
Sent: Friday, April 13, 2007 15:42
To: user@struts.apache.org
Subject: How to format util date with JSTL


How to format util date value with "YYYY-MM-DD HH:MM GMT" this format using
JSTL 1.0

Thanks,

Vinit
-- 
View this message in context:
http://www.nabble.com/How-to-format-util-date-with-JSTL-tf3573559.html#a9985
370
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message