libs/general_function.php
//** Format Tanggal DD-MM-YYYY **//
Format Tanggal DD-MM-YYYY
Format Tanggal DD - MM - YYYY
function dateTimeId($date){
	$date_id 		= date("Y-m-d H:i:s", $date);
	$month_array 	= date('m', strtotime($date_id));
	$date_array 	= substr($date_id, 8 , 2);
	$newDateTime 	= date('h:i A', strtotime($date_id));
    $day_array 		= date('w', strtotime($date_id));
    $year 			= substr($date_id, 2 , 2);
    $date_i 		= $month_array." ".$date_array."' ".$year." at ".$newDateTime."";
	if($date_i == '1970-01-01'){
		return '';
	} else {
		return $date_i;
	}
}
function dateTimeId ( $ date ) { $ date_id = date ( " Y-m-d H:i:s " , $ date ) ; $ month_array = date ( 'm' , strtotime ( $ date_id ) ) ; $ date_array = substr ( $ date_id , 8 , 2 ) ; $ newDateTime = date ( 'h:i A' , strtotime ( $ date_id ) ) ; $ day_array = date ( 'w' , strtotime ( $ date_id ) ) ; $ year = substr ( $ date_id , 2 , 2 ) ; $ date_i = $ month_array . " " . $ date_array . " '  " . $ year . "  at  " . $ newDateTime . " " ; if ( $ date_i == '1970-01-01' ) { return '' ; } else { return $ date_i ; } }
Format Tanggal DD-MM-YYYY
Format Tanggal DD - MM - YYYY