Indonesia
<!-- Tambahkan kode berikut pada area <body> --> <!-- http://www.downcodes.com/js --> <!-- bbs http://bbs.downcodes.com - - > <SCRIPT LANGUAGE="JavaScript"> <!-- Mulai var bulan = new Array("Januari","Februari","Maret","April","Mei","Juni","Juli"," Agustus", "September", "Oktober", "November", "Desember"); var hari = new Array("Minggu", "Senin", "Selasa", "Rabu", "Kamis", "Jumat", "Sabtu"); var mtend = Array baru(31,28,31,30,31,30,31,31,30,31,30,31); var opt = Array baru("waktu yang lalu","waktu yang akan datang "); function getDateInfo() { var y = document.form.year.value; var m = document.form.month.options[document.form.month.options.selectedIndex].value; var d = document.form. hari.pilihan[dokumen.form.hari.pilihan.indeks yang dipilih].nilai; var hlpr = mtend[m]; jika (d < mtend[m] + 1) { jika (m == 1 && y % 4 == 0 ) { hlpr++; } var c = Tanggal baru(y,m,d); var dayOfWeek = c.getDay(); document.form.dw.value = hari[dayOfWeek]; ().getTime()) { document.form.time.value = opt[1]; } else { document.form.time.value = opt[0] } else { alert("Hari ini"+bulan[ m]+" "+d+", "+y+" tidak ada.nSilakan pilih lagi."); function setY() { var y = new Date().getYear(); y += 1900; dokumen.form.tahun.nilai = } // Selesai --> </skrip> <form name="form"> <p><input type="text" name="year " ukuran ="8" value="2004">Tahun<pilih nama="bulan" size="1"> <opsi yang dipilih value="0">Januari</option> <option value="1">2 bulan</ option> <option value="2">Maret</option> <option value="3">April</option> <option value="4">Mei</option> <option value ="5">Juni </option> <option value="6">Juli</option> <option value="7">Agustus</option> <option value="8">September< /option> <option value="9" >Oktober</option> <option value="10">November</option> <option value="11">Desember</option> </select>< select name="day" size="1"> < opsi yang dipilih value="1">1</option> <option value="2">2</option> <option value="3">3</ option> <option value="4">4</ pilihan> <option value="5">5</option> <option value="6">6</option> <option value="7">7 </option> <option value="8">8 </option> <option value="9">9</option> <option value="10">10</option> <option value="11" >11</option> <option value="12" >12</option> <option value="13">13</option> <option value="14">14</option> <option value=" 15">15</option> <option value=" 16">16</option> <option value="17">17</option> <option value="18">18</option> <option value ="19">19</option> <nilai opsi ="20">20</option> <option value="21">21</option> <option value="22">22</option> < opsi value="23">23</option> < opsi value="24">24</option> <option value="25">25</option> <option value="26">26</option > <option value="27">27</option > <option value="28">28</option> <option value="29">29</option> <option value="30">30< /option> <option value="31">31< /option> </select>Hari<input type="button" value="Lihat informasi untuk hari ini" name="gdi" onClick="getDateInfo()" ></p> <p>Hari minggu ditampilkan di sini: <input type="text" name="dw" size="12">Status waktu: <input type="text" name="time" size=" 10"></p> </form >