Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

css help

Featured Replies

hi guys listen got a problem my nav bar wont meet the bottom of my header.

 

image below

 

untitled-2.jpg

 

and heres the css code i have written, can anyone help me and show me im going wrong.

 

body{
background: black;
font-family: helvetica, arial, "sans serif";
color: grey;
text-align: center;
}

#container{
width: 900px;
margin: 0px auto;
}

#header{
height: 150px;
background: url(photoshop/Bannercopy.jpg) no-repeat;
}

#content{
float: right;
width: 400px;
}

#nav{
height: 45px;
width: 900px;
background: url(photoshop/navcopy.jpg) no-repeat;
}

#nav ul li{

display: inline;
}

Try using a simple reset at the top of your css

* {
margin:0;
padding:0;
}

Some of your html would help too :)

  • Author

Thankyou very much

 

heres my html

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html>

<head>
<LINK href="htmltemp.css" rel="stylesheet" type="text/css">

</head>
<body>




<div id="container">

	<div id="header">
		</div>


	<div id="nav">
		<ul>
			<li>Home</li>
			<li>Server</li>
			<li>Downloads</li>
			<li>Admin</li>
		</ul>
	</div>



<div id="content">
	<p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a 	galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>

	<p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
</div>


</div>	
</body>
</html>

Set the margin of the <ul> inside your nav bar to 0:

 

#nav ul {
margin: 0;
}

My first question is:

 

How big is your header image? is it 150px in height?

 

Are you using transparent PNGs?

 

If so did you leave any space on the image?

 

A link to a site is so much more helpful.

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.