Java jsp根据参数默认选中radio

       <% int vol = (Integer)request.getAttribute("cardtype") ; %>

       <input type="radio" value="5" id="5"  <%= vol==5?"Checked":"" %> name="appendAmount3" >

       <input type="radio" value="10" id="10" <%= vol==10?"Checked":"" %> name="appendAmount3">

 

posted @ 2018-01-22 16:03  lgp20151222  阅读(259)  评论(0编辑  收藏  举报