Just a quick plug...

You can use fnDateTime() to get a properly formatted date string localized for your timezone.

Code:

fnDateTime("1-Aug-2005",3)