1

I am showing timedate select box by this code

public function configureFormFields(FormMapper $formMapper)
{

    $formMapper
        ->with('General')  

         ->add('toDate',null,array(                
                'widget' => 'choice');

however it uses english name for month label,such as Jan,Feb,Mar...

I want to use number instead of english label.

How can I do?

whitebear
  • 11,200
  • 24
  • 114
  • 237

1 Answers1

1
->add('toDate',null,array(        
                'format' => ''dd - M - yyyy'',        
                'widget' => 'choice');
parnas
  • 721
  • 5
  • 14
  • I see that I have typed up wrong quotes around format string, have you changed them? – parnas Apr 29 '13 at 20:20
  • I think your answer is correct,but in my circumstances I have to use 'date_format'. this is reference. http://stackoverflow.com/questions/16268813/format-for-time-display – whitebear Apr 30 '13 at 03:13