Search code examples
c#asp.netweb-applicationsiis-7pageload

.net page loading twice without reason


I have an unusual problem. Every page in my web application is loading twice! When debugging the onload event is hit twice. I have checked iis logs and have seen same.

My application is .net 3.5, asp.net c# running in IIS7.

It is occurring in multiple different environments.

It is not just one page but all pages on the site. To test this I created a blank page, with no markup eg. not empty source tags on images or iframe which I read may cause it. I also removed all httpmodules from web.config and httphandlers but its still occuring.

I am out of ideas now so anyone have any advice or tips for me?


Solution

  • There can be different reasons,

    • Check in different browsers, see if any addins cause that.
    • Check it if PostBack is calling next load
    • See if you are in debug mode then debug the code if possible to see how it really loads two times.