이미지 맵과 자바스크립트의 응용 (질병활성도 측정)
아래의 이미지에서 각 신체부위를 클릭하면 오른쪽의 해당 신체부위에 체크가 됩니다
|
|
------------------------------------------------------------------------------------------------------------------------------------------------
Patient global health VAS in mm (0-100)
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=EUC-KR"> <title>Patient global health VAS in mm (0-100)</title> <style type="text/css"> input {width:50px; border:1px solid black;} input.result { width:200px;} input.button{margin-left: 300px; } </style> <script type="text/javascript"> /* 0.56√TJC(28) + 0.28√SJC(28) +0.7 X In(ESR)+0.014X GH * Math.log(x) --> Returns the natural logarithm (base E) of x */ function getVAS() { var tjc = parseFloat(form2.tjc.value); var sjc = parseFloat(form2.sjc.value); var esr = parseFloat(form2.esr.value); var gh = parseFloat(form2.gh.value); var value = 0.56* Math.sqrt(tjc)+ 0.28*Math.sqrt(sjc) + 0.7 * Math.log(esr) + 0.014*gh; form2.result.value = value; } </script> </head> <body> <div style="border:1px solid black; width:400px; height:120px; padding-top:10px; padding-left:10px; padding-bottom:10px;"> <form name="form2" action="" method="post"> TJC <input type="text" name="tjc" value="28"/> SJC <input type="text" name="sjc" value="28"/> ESR <input type="text" name="esr" value="1"/> GH <input type="text" name="gh" value="1"/> <br/><br/> <input class="button" type="button" value="계 산" onClick="getVAS()"/> <br/><br/> 결과 <input class="result" type="text" name="result" /> </form> </div> </body> </html>
src.zip
imagemap.exe