Returns the JS code needed to initialise a Date() object with the specified date. This should only be used for dates. For times or date-times, use a different function. From types: 'mysql' - a mysql-formatted date in the form YYYY-MM-DD 'array' - an array [ <day> , <month> , <year> ]