This forum is in READ-ONLY mode.
You can look around, but if you want to ask a new question, please use Stack Overflow.

How to get date value from sfWidgetFormDate?(symfony 1.4)

Discussion relating to version 1.3.x and 1.4.x

How to get date value from sfWidgetFormDate?(symfony 1.4)

by laszlo » Tue Aug 26, 2014 7:23 am

Hi all,

I am new to symfony.
I get a nasty problem: How to get date value from sfWidgetFormDate?

My form:
$this->setWidget('BIRTH_DATE', new sfWidgetFormDate(array()));
$this->setValidator('BIRTH_DATE', new sfValidatorDate(array(
'required' => false
),array(
'required' => '生年月日は必須です。'
)));

Front page:
if($widget instanceof sfWidgetFormDate){
$date = $widget->getDate();
echo $date;
}

Please help me, thank you in advance.
laszlo
Junior Member
 
Posts: 1
Joined: Tue Aug 26, 2014 7:15 am