php - Yii Full month name in CGrivView -


i have smth

array( 'name'=>'date', 'type'=>'date', 'value'=>'date("m j, y", $data->date)', ), 

and it's showing date in format year/month/day in numbers, want full name of month : 10 september 2014. searched internet, nothing me problem..

try

    array(         'name'=>'date',         'type'=>'date',         'value'=>'yii::app()->dateformatter->formatdatetime(cdatetimeparser::parse($data->date, "yyyy-mm-dd"),"medium",null)'     ), 

edit:

tested code: have tested code may you.

<?php     $date=date('yyyy-mm-dd');     $form=yii::app()->dateformatter->formatdatetime(cdatetimeparser::parse($date, "yyyy-mm-dd"),"medium",null);     cvardumper::dump($form,100,true);     die();     ?> 

it returns me

'feb 1, 2014' 

Comments

Popular posts from this blog

html - Sizing a high-res image (~8MB) to display entirely in a small div (circular, diameter 100px) -

java - IntelliJ - No such instance method -

identifier - Is it possible for an html5 document to have two ids? -