<ul data-role='listview' data-inset='true' data-divider-theme='b'>
<li data-role='list-divider'>
<label>Radio Button</label>
</li>
<li data-theme='c'>
<fieldset data-role='controlgroup'>
<input id='radio1' type='radio' name='Delete' />
<label for='radio1'>Radio 1</label>
<input id='radio2' type='radio' name='Delete' />
<label for='radio2'>Radio 2</label>
</fieldset>
</li>
</ul>
<div data-role='navbar'>
<ul data-inset='true'>
<li><a data-role='button' href='#' id='delete' data-icon='check'>Ok</a></li>
<li><a data-role='button' href='#' id='Cancel' data-icon='delete'>Cancel</a></li>
</ul>
</div>
$("input[type='radio']").checkboxradio("refresh");
var radTrn = $("#radio1").attr('checked');//here it is coming as undefined
var radRstAl = $("#radio2").attr('checked');//here it is coming as undefined
使用jQuery Mobile的簡單的對話框RAW HTML mode.The單選按鈕,檢查IM在jQuery的1.6.4工作,並在1.7.1它不工作如何檢查jquery新版本1.7.1中的單選按鈕?
什麼不起作用?因爲你從來沒有真正說過你真的想在這裏做什麼。你是否試圖以編程方式選擇單選按鈕,你想要測試它的當前狀態還是其他?請同時發佈您的相關HTML代碼。 – Sparky 2012-03-16 04:31:26
現在我給出了相關的HTML代碼。 – 2012-03-16 10:16:16
回覆我sparky672 – 2012-03-20 06:35:18