brookesmash
brookesmash

Reputation: 95

asp .net Validation not working in IE 10

Has anyone come across this issue? I have required field validation on a form that I have tested and know works in IE 7-9, Firefox and Chrome but in IE 10 it allows the form to submit without doing any validation. The site is in .Net 3.5. I have done some research online but I can't find anything about this.

Upvotes: 3

Views: 5504

Answers (3)

Hardik Mali
Hardik Mali

Reputation: 11

Hope this can help out.

protected void Page_Init(object sender, EventArgs e)
    {
        Page.ClientTarget = "uplevel";
    }

Upvotes: 1

Wiktor Zychla
Wiktor Zychla

Reputation: 48279

Most probably support.microsoft.com/kb/2608565.

Which means that your old browser capabilities settings incorrectly recognize ie10 as a browser which doesn't support javascript (which of course is not true). The updated browser capabilities file corrects this problem.

Upvotes: 4

brookesmash
brookesmash

Reputation: 95

So I figured out a way around it. I had tried the hotfix and that didn't fix it but I added in Page.IsValid to the submit and it works fine now. I didn't think this would matter since validation is normally client side only but it seemed to do the trick.

Edit: I originally used an incorrect hotfix as mentioned support.microsoft.com/kb/2608565 will fix this issue. Also as mentioned I should always have the Page.IsValid in my submits in case javascript is turned off.

Upvotes: 1

Related Questions