Web page with different display with local address and IP address

I am having a strange problem with my site today. I have local code in aspx that I can view perfectly in ie and firefox, I publish it on my computer and create a virtual website and then view it both with firefox and with http: // localhost / testwebsite /default.aspx , and it is also displayed fine, but when switching from the local host to the local IP address, the page is displayed strangely in the layout of the elements, they are in a strange order, not as they should.

I can not understand this problem? This is some new problem. What is so different when viewed on localhost and ip for the same published code. The only doubt concerned the relative paths of css and javascript, but we checked them and they look fine.

+5
source share
4 answers

Try adding the following meta tag to your page title:

<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />

I had a similar problem with IE8 that caused my intranet site to be browsed in IE7 compatibility mode.

+10
source

IE8, IE7. " " | "". ( MarkKBS, )

+1

IE9, F12 " " IP- "localhost". , IP IE8.

+1

Try using something like Firebug to make sure all file links are actually correct. You may be missing the default CSS, which is mostly overridden. If you install firebug, you can see that even if you requested a file that you did not receive, plus a number of other things that may help in future scenarios.

0
source

All Articles