<html><head><title>¹ÙÀÌ¿À¸®µë</title> <script>
function ck(form) { var a=new Date();
var b_year; var b_month; var b_day;
var t_year; var t_month; var t_day;
if (!form.by.value) { b_year = 1977; b_month = 1; b_day = 14; } else { b_year=form.by.value; b_month=form.bm.value; b_day=form.bd.value; }
if (!form.by.value) { t_year = a.getYear(); t_month = a.getMonth(); t_day = a.getDate(); } else { t_year=form.by.value; t_month=form.bm.value; t_day=form.bd.value; }
var b_hour = 1; var b_min = 1; var b_sec = 1;
var total=a.getTime();
total/=60*60*24;
var myt = new Date(b_year,b_month,b_day,b_hour,b_min,b_sec); myt = myt.toGMTString(); var my_total=Date.parse(myt);
my_total/=60*60*24;
var totalday = total - my_total;
var pis = 3.141592654;
var physical = Math.sin((totalday / 23) * 2 * pis) * 100;
var emotional = Math.sin((totalday / 28) * 2 * pis) * 100;
var mental = Math.sin((totalday / 33) * 2 * pis) * 100;
var intuitive = Math.sin((totalday / 38) * 2 * pis) * 100;
physical = parseInt(physical); emotional = parseInt(emotional); mental = parseInt(mental); intuitive = parseInt(intuitive);
document.write('ÀÚ¹Ù½ºÅ©¸³Æ® ¹ÙÀÌ¿À¸®µë<table><tr>');
width=physical; if (width<0) { width=-physical; document.write('<td><hr size=2 color=blue align=right width='+width+'></td><td width=100> ü·Â : '+physical+'</td><td></td></tr>'); } else { width=physical; document.write('<td></td><td> ü·Â : '+physical+'</td><td><hr size=2 color=red align=left width='+width+'></td></tr>'); }
width=emotional; if (width<0) { width=-emotional; document.write('<td><hr size=2 color=blue align=right width='+width+'></td><td> °¨¼º : '+emotional+'</td><td></td></tr>'); } else { width=emotional; document.write('<td></td><td> °¨¼º : '+emotional+'</td><td><hr size=2 color=red align=left width='+width+'></td></tr>'); }
width=mental; if (width<0) { width=-mental; document.write('<td><hr size=2 color=blue align=right width='+width+'></td><td> Áö°¢ : '+mental+'</td><td></td></tr>'); } else { width=mental; document.write('<td></td><td> Áö°¢ : '+mental+'</td><td><hr size=2 color=red align=left width='+width+'></td></tr>'); }
width=intuitive; if (width<0) { width=-intuitive; document.write('<td><hr size=2 color=blue align=right width='+width+'></td><td> Áö¼º : '+intuitive+'</td><td></td></tr>'); } else { width=intuitive; document.write('<td></td><td> Áö¼º : '+intuitive+'</td><td><hr size=2 color=red align=left width='+width+'></td></tr>'); } document.write('</table>'); } </script> </head> <body> <form name=f><table><tr><td colspan=2>ÀÚ¹Ù½ºÅ©¸³Æ® ¹ÙÀÌ¿À¸®µë</td></tr> <tr><td>»ý³â¿ùÀÏ (¾ç·Â)</td><td><input type=input name=by size=4 value=1977>³â <input type=input name=bm size=2 value=1>¿ù <input type=input name=bd size=2 value=14>ÀÏ</td></tr> <tr><td>¾Ë¾Æº¼ ³¯Â¥ÁöÁ¤ </td><td> <script> var z=new Date();
var t_year = z.getYear(); var t_month = z.getMonth(); var t_day = z.getDate();
var total=z.getTime();
document.write('<input type=input name=ty size=4 value='+t_year +'>³â'); document.write(' <input type=input name=tm size=2 value='+t_month+'>¿ù'); document.write(' <input type=input name=td size=2 value='+t_day+'>ÀÏ'); </script> <input type=button value=º¸±â onClick="ck(this.form)"></td></tr></table> </form> </body> </html>
|