if(typeof date=='number'){
date=new Date(date);
}
- var monthNames = [ t('files','January'), t('files','February'), t('files','March'), t('files','April'), t('files','May'), t('files','June'),
- t('files','July'), t('files','August'), t('files','September'), t('files','October'), t('files','November'), t('files','December') ];
- return monthNames[date.getMonth()]+' '+date.getDate()+', '+date.getFullYear()+', '+((date.getHours()<10)?'0':'')+date.getHours()+':'+((date.getMinutes()<10)?'0':'')+date.getMinutes();
+ return $.datepicker.formatDate(datepickerFormatDate, date)+' '+date.getHours()+':'+((date.getMinutes()<10)?'0':'')+date.getMinutes();
}
/**
<?php
$LOCALIZATIONS = array(
+ 'jsdate' => 'dd.mm.yy',
'date' => '%d.%m.%Y',
'datetime' => '%d.%m.%Y %H:%M:%S',
'time' => '%H:%M:%S',
<?php
$LOCALIZATIONS = array(
+ 'jsdate' => 'MM d, yy',
'date' => '%B %e, %Y',
'datetime' => '%B %e, %Y %H:%M',
'time' => '%H:%M:%S',
<?php
$LOCALIZATIONS = array(
+ 'jsdate' => "d 'de' MM 'de' yy",
'date' => '%e de %B de %Y',
'datetime' => '%e de %B de %Y %H:%M',
'time' => '%H:%M:%S',
var oc_current_user = '<?php echo OC_User::getUser() ?>';
var oc_requesttoken = '<?php echo $_['requesttoken']; ?>';
var oc_requestlifespan = '<?php echo $_['requestlifespan']; ?>';
+ var datepickerFormatDate = <?php echo json_encode($l->l('jsdate')) ?>;
var dayNames = <?php echo json_encode(array((string)$l->t('Sunday'), (string)$l->t('Monday'), (string)$l->t('Tuesday'), (string)$l->t('Wednesday'), (string)$l->t('Thursday'), (string)$l->t('Friday'), (string)$l->t('Saturday'))) ?>;
var monthNames = <?php echo json_encode(array((string)$l->t('January'), (string)$l->t('February'), (string)$l->t('March'), (string)$l->t('April'), (string)$l->t('May'), (string)$l->t('June'), (string)$l->t('July'), (string)$l->t('August'), (string)$l->t('September'), (string)$l->t('October'), (string)$l->t('November'), (string)$l->t('December'))) ?>;
var firstDay = <?php echo json_encode($l->l('firstday')) ?>;
* Localization
*/
private $localizations = array(
+ 'jsdate' => 'dd.mm.yy',
'date' => '%d.%m.%Y',
'datetime' => '%d.%m.%Y %H:%M:%S',
'time' => '%H:%M:%S',
return strftime($this->localizations[$type], $data);
break;
case 'firstday':
+ case 'jsdate':
return $this->localizations[$type];
default:
return false;