Results 1 to 2 of 2

Thread: [RESOLVED] CSS doesn't work fully unless I use localhost

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Feb 2010
    Posts
    156

    Resolved [RESOLVED] CSS doesn't work fully unless I use localhost

    I have an issue with an aspx page I have created but I decided to break it down into its smallest component and then see if anyone knew what I was missing.
    If I create a new webform called default.aspx and add the code posted below it doesn't load all of the css when accessing the page remotely in IE11

    (I use IIS7)

    it works fine in google as
    http://localhost:8080/default.aspx
    or
    http://servername:8080/default.aspx

    but in IE11 it only works as
    http://localhost:8080/default.aspx
    anything else causes the fault in the attached image.

    Any help would be much appreciated.


    Code:
    <%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %>
    
    <!DOCTYPE html>
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
        <title>testing</title>
        <style type="text/css">
            #head {
    	            margin-top:15px;
    	            margin-left: auto;
                        margin-right: auto;
    	            min-height:24px;
    	            background: linear-gradient(#10b9ce, #08b1c6);
    	            border-top-left-radius: 30px;
      	            border-top-right-radius: 30px;
      	            border-width: 1px;
      	            border-color: #999;
      	            border-style: solid;
      	            border-bottom-width: 0px;
      	            width:1280px;
                        text-align: center;
                        padding-top: 4px;
                   }
        </style>
    </head>
    <body>
        <form id="form1" runat="server">
            <div id="head">
                Testing my CSS in IE
    	</div>
        </form>
    </body>
    </html>
    Name:  iecss.jpg
Views: 321
Size:  15.0 KB

  2. #2

    Thread Starter
    Addicted Member
    Join Date
    Feb 2010
    Posts
    156

    Re: CSS doesn't work fully unless I use localhost

    Answer without knowing why is to add
    <meta http-equiv="X-UA-Compatible" content="IE=11">
    to the header

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width