我正嘗試創建出現在選擇標記中的複選框列表。我搜索了很多文章,我沒有得到適當的輸出。請幫我解決這個問題。如何使用struts2在選擇框中添加複選框
<s:checkboxlist list = "%{cityList}"
name = "cityNo"
id = "cityNo"
cssClass = "margin-right margin-top required-field"
cssStyle = "width: 114px;height:30px"
headerKey = "0"
headerValue = "City"
listKey = "id"
listValue = "cityName"
onfocus = "getcitywithCountry(false);" />
你應該指定如何這是行不通的。您遇到哪種錯誤等等...... –
您想在選擇標籤中選擇每個選項的複選框嗎? –
錯過了「在選擇標記」部分...然後:http://stackoverflow.com/questions/17714705/how-to-use-checkbox-inside-select-option –