Archives: Date

Java – Calculate Difference Between Two Dates Using Joda Time

Take a look @ Joda-Time FAQ

You can use a PeriodFormatter to get the format of your choice.

Try the following sample code.


Java JSP – JSTL Date Format Example

This example show how to format date in JSP using format tag library.


Java – Convert java.util.Date to JodaTime

Make sure date isn’t null, though, otherwise it acts like new new DateTime()