This appears to be a problem with a incorrectly configured webserver, rather than a problem with the browser.
As far I can tell, it's the server upon which the website is hosted, that may be incorrectly set to send HTML
files as text/plain instead of text/html. Try getting the server reconfigured to serve webpages as text/html.
Since Internet Explorer effectively ignores the key part of the HTTP standard that deals with this, then IE
will more than likely display the page as a webpage and not raw code, no matter how the server is set up.
HTTP is the protocol for the World Wide Web. It provides requirements that all Web browsers must
meet; if browsers developed their own protocol instead, communication between computers would
break down and the Internet would collapse into anarchy. (HTTP = Hypertext Transfer Protocol)
Internet Explorer does not obey this important internet protocol!
When a server sends a file to you through HTTP, it identifies the file as a webpage, text file,
picture file, movie, or other type of file. HTTP uses the Content-Type header to do this.
The protocol for HTTP/1.1 states:
"If and only if the media type is not given by a Content-Type field, the recipient
may attempt to guess the media type via inspection of its content and/or
the name extension(s) of the URI used to identify the resource."
Internet Explorer does not follow these rules; it guesses the media type of every file it receives.
Even if I send it a file with "Content-Type: image/jpeg", if Internet Explorer thinks it's a text file,
it will open it like a text file! If in the future IE starts identifying its Content-Types incorrectly,
this will cause a huge dilemma with webmasters. Because it does not follow this clear
protocol, Internet Explorer cannot be technically identified as a "web browser".
UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.1) Gecko/20040707
SeaMonkey = Swiss Army Knife: It's versatile, reliable, and contains useful tools.
Windows Internet Explorer = Old Swiss Cheese: Full of holes, and it stinks!