Drupal form API date popup
To make a correct format you can make use of #default_value 

See here


  Description: Format a date selection box. The #default_value will be
  today's date if no value is supplied. The format for the #default_value and the #return_value is an array with three elements with the keys: 'year', month', and 'day'. For example, array('year' =>
  2007, 'month' => 2, 'day' => 15)