Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
根据这个线程,我们可以使用语法$("element[id$='txtTitle']")来选择 id 以“txtTitle”结尾的所有元素。我们如何使用这种语法使用多个 id。
$("element[id$='txtTitle']")
render
render="@([id$=txtTitle])"
如果用逗号分隔,则可以访问多个集合
var sets =$("element[id$='txtTitle'], element[id$='txtName']");