RSS

Format Tanggal PHP Dalam Bahasa Indonesia

13 Jun

‘Senin’,’Selasa’,’Rabu’,’Kamis’,’Jumat’, ‘Sabtu’,’Minggu’);

$hari = $array_hari[date(‘N’)];

//Format Tanggal

$tanggal = date (‘j’);

//Array Bulan

$array_bulan = array(1=>’Januari’,’Februari’,’Maret’, ‘April’, ‘Mei’, ‘Juni’,’Juli’,’Agustus’,’September’,’Oktober’, ‘November’,’Desember’);

$bulan = $array_bulan[date(‘n’)];

//Format Tahun

$tahun = date(‘Y’);

//Menampilkan hari dan tanggal

echo $hari . “,” . $tanggal . $bulan . $tahun;

?>

src: http://adhit.web.id/format-tanggal-php-dalam-bahasa-indonesia/

 
Leave a comment

Posted by on June 13, 2011 in Computer, PHP

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: