Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Jul 2011
    Thanked 0 Times in 0 Posts

    Navbar div background, Chrome, resize, gap

    Dear all, a quick question - there is something wrong with Chrome, because when I try to resize window (zoom), it creates a gap between the main navbar and the right div (with rounded edges). IE and Firefox work perfectly.

    Does anyone know why this happens and how to help? Thanks. Here is the code:

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
    <meta name="description" content=""> 
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> 
    <style type="text/css">
    body, html
    {margin: 4px 0px 0px 0px;
    padding: 0px;}
    {position: absolute;
    width: 8px;
    height: 36px;
    float: left;
    background: url('http://www.shrani.si/f/q/l4/VaHWUz1/navld.png');}
    {margin: 0 auto;
    width: 800px;
    height: 36px;
    text-indent: 6px;}
    #navbar .inbar
    {margin-left: 8px;
    display: block;
    height: 36px;
    float: left;
    width: 784px;
    background: url('http://www.shrani.si/f/1v/11x/1yv5DwU6/nav-bg.png');}
    {width: 8px;
    height: 36px;
    float: right;
    background: url('http://www.shrani.si/f/q/l4/VaHWUz1/navld.png');
    background-position: top right;}
    <div id="navbar">
    <div id="nav-l"></div>
    <span class="inbar"></span>
    <div id="nav-r"></div>
    Last edited by bart77; 07-18-2011 at 10:47 AM.

  2. #2
    Registered User
    Join Date
    Jun 2011
    Thanked 241 Times in 240 Posts

    border-radius: ;
    -webkit-border-radius: ;
    -moz-border-radius: ;

    in the future


    try floating the right end to the left instead of the right. this will fix the problem, but in the future you want to position: absolute; the ends with NEGATIVE values. In any case, you should really just use css (border-radius) to make curves
    Last edited by Sammy12; 07-18-2011 at 07:34 PM.


Tags for this Thread

Posting Permissions

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