Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $tglsekarang = date('d-m-Y');
- $tgljatuhtempo ='30-05-2013';
- $pecah1 = explode("-", $tgljatuhtempo );
- $date1 = $pecah1[0];
- $month1 = $pecah1[1];
- $year1 = $pecah1[2];
- $pecah2 = explode("-", $tglsekarang);
- $date2 = $pecah2[0];
- $month2 = $pecah2[1];
- $year2 = $pecah2[2];
- $waktusekarang = GregorianToJD($month1, $date1, $year1);
- $waktuinput = GregorianToJD($month2, $date2, $year2);
- echo $selisih = $waktusekarang - $waktuinput; echo " Hari";
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement