ASP.NET 2.0: Bug - XHTML - Javascript Rendering
Suppose the following scenario:
- Default XHTML conformance (transitional).
- Webform with textboxes, submit button and RequiredFieldValidator fields.
Since submit button onsubmit attribute is rendered as follows in IE 7:
javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl02", "", true, "", "", false, true))"
It causes javascript error in IE 7 (annoying small yellow js error icon at the bottom-left). Missing semi-colon [ ; ]. While everything works fine (form submits normally).
I don't get javascript error when either of the following:
- Using FF.
- Using enableclientscript="false" attribute for RequiredFieldValidator (no javascript, validation is server-side).
- Using Legacy attribute for XHTMLconformance in web.config.
Saturday, January 6, 2007 6:23 AM