下面是我做的一个关于抑郁症的简单的心理测试网站。测试者根据问题选择选项,利用js统计得分,单击按钮显示测试得分及心理状况。
HTML代码
<form name="see">
<p><b>1、你是否感到食欲不振?或情不自禁地暴饮暴食?</b></p>
<p>
<input onclick="begintimer()" type="radio" value="12" name="c1" />没有
<input onclick="begintimer()" type="radio" value="32" name="c1" />轻度
<input onclick="begintimer()" type="radio" value="32" name="c1" />中度
<input onclick="begintimer()" type="radio" value="32" name="c1" />严重
</p>
<p><b>2、你是否患有失眠症?或整天感到体力不支,昏昏欲睡?</b></p>
<p>
<input type="radio" value="11" name="c2" />没有
<input type="radio" value="31" name="c2" />轻度
<input type="radio" value="31" name="c2" />中度
<input type="radio" value="31" name="c2" />严重
</p>
<p><b>3、你是否丧失了对性的兴趣?</b></p>
<p>
<input type="radio" value="11" name="c3" />没有
<input type="radio" value="31" name="c3" />轻度
<input type="radio" value="31" name="c3" />中度
<input type="radio" value="31" name="c3" />严重
</p>
<p><b>4、你是否经常担心自己的健康?</b></p>
<p>
<input type="radio" value="13" name="c4" />没有
<input type="radio" value="33" name="c4" />轻度
<input type="radio" value="33" name="c4" />中度
<input type="radio" value="33" name="c4" />严重
</p>
<p><b>5、你是否认为生存没有价值,或生不如死?</b></p>
<p>
<input type="radio" value="14" name="c5" />没有
<input type="radio" value="34" name="c5" />轻度
<input type="radio" value="34" name="c5" />中度
<input type="radio" value