<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<?php 
include_once 'class.banglaDate.php';
$bn = new BanglaDate(time());
print_r($bn->get_date());
echo '<br>';
$bn->set_time(time(), 0);
print_r($bn->get_date());
echo '<br>';
$bn->set_time(strtotime('18-03-1988'), 0);
print_r($bn->get_date());
echo '<br>';
$bn->set_time(strtotime('18-03-1988'), 6);
print_r($bn->get_date());
Example #2
0
    ?>
</p>
<?php 
}
?>


<?php 
if (!Yii::app()->user->isGuest) {
    ?>
<p>
আপনার শেষ লগ ইন 
    <?php 
    $locale = Yii::app()->getLocale('bn_bd');
    Yii::import('application.apis.*');
    $BanglaDate = new ShowBanglaDateTime();
    $bn = new BanglaDate(time());
    $bn->set_time(Yii::app()->user->lastLoginTime);
    $bdate = $bn->get_date();
    echo $BanglaDate->bangla_date_time(date('l', Yii::app()->user->lastLoginTime)) . ', ' . $bdate[0] . ' ' . $bdate[1] . ' ' . $bdate[2] . ' ' . $BanglaDate->bangla_date_time(date('h:i:s A', Yii::app()->user->lastLoginTime)) . '( ';
    echo $locale->dateFormatter->formatDateTime(Yii::app()->user->lastLoginTime, 'full') . ' )';
    ?>
</p>
<?php 
    //    echo '<br><hr>';
    //    echo $locale->numberFormatter->formatCurrency(123.12, 'BDT');
    //    $int = 123.12;
    //    $engNumber = array(1,2,3,4,5,6,7,8,9,0);
    //    $bangNumber = array('১','২','৩','৪','৫','৬','৭','৮','৯','০');
    //    echo $converted = str_replace($engNumber, $bangNumber, $int);
}