_ctl0 vs ctl00
ASP.Net 2.0中把默认的control ID前缀从_ctl0改为ctl00了,可能有很多依赖control ID的代码会无法正常工作。
其实Web.Config中有下面这个选项可以控制:
xhtmlConformance Element (ASP.NET Settings Schema)
http://msdn2.microsoft.com/en-us/library/ms228268.aspx
<system.web>
<xhtmlConformance mode="Legacy"/>
当然最理想的做法还是动态取Control.ClientID。posted on 2006-11-22 16:25:00 by TingWang 评论(2) 阅读(6680)