html - How to keep nav bar from shifting elements to next line when zooming in? -


edit: solved jirikuchta! added white-space: nowrap; #navigation in css. read on more information on problem fixed. hope can else out there!

i've seen question hundred times on internet on past few days trying fix problem, absolutely nothing has worked me. when zoom @ in google chrome, nav bar shifts last link next line, ruining whole layout. i'm new html first real roadblock i've run into, , i'm absolutely stumped. i've followed advice on countless other websites, adding min-width , max-width, wrappers, positions, switched em , %, nothing has worked. i'm assuming problem when zoom, things round , make things big space provided, don't know how counter problem. in advance , help!

html:

<!doctype html> <html> <head> <meta charset="utf-8"> <title>about</title> <link rel="shortcut icon" type="image/x-icon" href="layoutimages/favicon.png"> <link href='http://fonts.googleapis.com/css?family=raleway:400,800' rel='stylesheet' type='text/css'> <link href="webpage.css" rel="stylesheet" type="text/css"> <script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script> <link rel="stylesheet" href="fancybox/source/jquery.fancybox.css" type="text/css" media="screen" /> <script type="text/javascript" src="fancybox/source/jquery.fancybox.pack.js"></script> </head>  <body> <div id="container"> <nav>     <div id="navigation">         <ul>             <li><a href="index.html">home</a></li><li><a href="about.html">about</a></li><li><a href="milk.html">milk</a></li><li><a href="farm.html">the farm</a></li><li><a href="contact.html">contact</a></li>     </ul>   </div> </nav> <div id="banner"><img src="layoutimages/aboutbanner.png" width="955" height="400" draggable="false" style="-moz-user-select: none; display:block; " /></div> 

css:

@charset "utf-8";  body, h1, h2, h3, h4, h5, h6, p, ul, ol, li, address, blockquote {     margin: 0px;     padding: 0px;     font-size: 16px/9px;     font-style: normal; } html {     background-color:#f8f7e4; } #container {     width:955px;     height:auto;     background-color:#d2d2de;     margin-left:auto;     margin-right:auto;     position:relative; } #navigation li {     font: 35px arial black;     display: inline; } #navigation {     padding:9px 35px;     background-color:#0080c2;     color:#f8f7e4;     text-decoration:none; } #navigation a:hover {     background-color:#f8f7e4;     color:#000; } 

i can tell there's i'm not understanding, need figure out. i've been struggling few days now.

additionally, reason i'm concerned zooming site viewed parents' computer, , have chrome set 125% zoom better visibility.

not sure if helps can try apply white-space: nowrap #navigation element.


Comments

Popular posts from this blog

Java 3D LWJGL collision -

spring - SubProtocolWebSocketHandler - No handlers -

methods - python can't use function in submodule -