2
讓我們說一個aspx頁面我有一個for循環,並且在for循環中我想創建元素。我怎樣才能爲他們動態生成id。HTML ELements的動態ID
舉例來說,如果我有:
<div>
<% Foreach (item in itemCollection) { %>
{
<table>
<tr>
here I want to create td elements with id as reconText1 reconText2...the numbers at the end I get by incrementing the index.
</tr>
</table>
}
</div>