ASP.NET XML Parsing Error: no element found Line Number 1, Column 1 Error

后端 未结 12 2186
[愿得一人]
[愿得一人] 2021-02-20 05:44

Hey I found a weird temperamental page which randomly gives me the following error

XML Parsing Error: no element found
Location: http://kj2011/site_2011/nonprofit-data         


        
相关标签:
12条回答
  • 2021-02-20 05:47

    App_Themes folder was missing when I got this.

    0 讨论(0)
  • 2021-02-20 05:50

    I just debugged this issue on my website. In my case, the cause was a call to Response.End() . You can recreate the error by dropping Response.End() as the first line of Page_Load.

    From MSDN ms524629:

    The Response.End method causes the Web server to stop processing the script and return the current result. The remaining contents of the file are not processed.

    In my case, Response.End() was being called before any content was written to the buffer. Also, there was no Content-Type in the response header (see attached Firebug screen grabs). My guess is because of these two factors, Firefox didn't know what to make of it and by default it tried to process it as a an XML file.

    In your situation, my guess is the extra View.aspx file caused an exception that was interrupting page rendering cycle.

    http://i.stack.imgur.com/wpLrt.png

    http://i.stack.imgur.com/LE59C.png

    0 讨论(0)
  • 2021-02-20 05:55

    The most likely cause for such problem is security, if the problem occurs! check file security and make sure its accessible by asp.net process. (ASP.NET Required Access Control Lists (ACLs)), also does this occur with local calls on the same server?

    Another thing is to check your page and make sure you don't have one or more unclosed tags in your markup.

    0 讨论(0)
  • 2021-02-20 05:58

    This was an issue with an external DLL, which created a page called view.aspx in the same folder which caused an issue with our overview.aspx. We just renamed the page and the issue went away.

    0 讨论(0)
  • 2021-02-20 05:59

    That sounds like the Firefox error page that's returned when FF expects HTML and gets an empty document instead. Try looking at it with Firebug enabled and see what the Net tab says - perhaps you have a good header, but no html.

    Usually that kind of thing is not due to an ASP.NET error (since with those you still have a document body for the Yellow Screen of Death page), but is more along the lines of a networking error...

    Would it be possible to try looking at it from another computer to see if that's the problem?

    0 讨论(0)
  • 2021-02-20 06:01

    Just to cover all the possibilities. Today I got the same error, no matter the page I was trying to access, but it was a completelly unrelated issue.

    For some reason, Skype loaded before IIS on Windows startup and took control of port 80, instead of the usual 17112. Whenever I tried to access a page Skype returned an empty response.

    You can simply shut down Skype and reset IIS, but to make sure it never happens again do the following:

    Go to:

    Skype > Tools > Options > Advanced > Connection

    And uncheck Use port 80 and 443 as alternative for incomming connections

    0 讨论(0)
提交回复
热议问题