Skip to content
This repository has been archived by the owner on Dec 17, 2018. It is now read-only.

Update cmb_Meta_Box_types.php #506

Merged
merged 1 commit into from
Apr 7, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions helpers/cmb_Meta_Box_types.php
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ public function wysiwyg( $args = array() ) {

public function text_date_timestamp() {
$meta_value = $this->field->escaped_value();
$value = ! empty( $meta_value ) ? date( 'm\/d\/Y', $meta_value ) : '';
$value = ! empty( $meta_value ) ? date( $this->field->args( 'date_format' ), $meta_value ) : '';
return $this->input( array( 'class' => 'cmb_text_small cmb_datepicker', 'value' => $value ) );
}

Expand All @@ -465,14 +465,14 @@ public function text_datetime_timestamp( $meta_value = '' ) {
'class' => 'cmb_text_small cmb_datepicker',
'name' => $this->_name( '[date]' ),
'id' => $this->_id( '_date' ),
'value' => ! empty( $meta_value ) ? date( 'm\/d\/Y', $meta_value ) : '',
'value' => ! empty( $meta_value ) ? date( $this->field->args( 'date_format' ), $meta_value ) : '',
'desc' => '',
) ),
$this->input( array(
'class' => 'cmb_timepicker text_time',
'name' => $this->_name( '[time]' ),
'id' => $this->_id( '_time' ),
'value' => ! empty( $meta_value ) ? date( 'h:i A', $meta_value ) : '',
'value' => ! empty( $meta_value ) ? date( $this->field->args( 'time_format' ), $meta_value ) : '',
'desc' => $desc,
) )
);
Expand Down