The Lodge is members-only design/dev videos and Office Hours.

Next Office Hours Session: "Implementing an SVG Icon System" Nov 30 - 6:00 PM Eastern

Border wont show in other browsers.

  • Anonymous
    # March 5, 2013 at 8:34 pm

    I have a border inside the iframe page and it displays perfectly in Chrome and Safari. But it wont display properly in Firefox or Opera. Does it have something to do with the doctype?
    [ website.]( “”)

    # March 5, 2013 at 9:13 pm

    Show us the CSS code you are using for border?

    # March 5, 2013 at 9:21 pm


    border:dotted 2px #000000;
    box-shadow:inset 0px 0px 10px black;

    Better yet here’s a pen [pen]( “”)

    # March 5, 2013 at 9:46 pm

    I’m guessing it’s because you are using iframes. As there are inconsistencies between browsers. Here are some [thoughts on iframes on StackOverflow](

    # March 5, 2013 at 9:58 pm

    Try using a fixed height of 428px for the body in the css for your iframe.

    # March 5, 2013 at 10:50 pm

    @eatyourbrians didn’t work.

    # March 6, 2013 at 8:15 am

    This reply has been reported for inappropriate content.

    The border is there in FF, but the body has 0 height. You might wanna look into that. Either another type of clearfix or a workaround like setting height on the body inside the iframe.

    # March 6, 2013 at 10:39 am

    @CrocoDillon Thanks bro. I gave the body a height of 420px and it works.

    @eatyourbrians You actually mentioned that first but for some reason i didn’t try it. Thanks to you too.

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed