Pregunta

Normally I use the following to display a Date object in a JSP page:

<fmt:formatDate value="${blogEntry.created}"/>

Works great if blogEntry.created is a java.util.Date object. But what's the proper way to display a date if you only have a date in milliseconds? Do I have to first set a variable with escaped Java code like <%=new java.util.Date(millis);%>? Or is there a better way?

No hay solución correcta

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top