HTML ad CSS background positioning an icon - html

I am working on my website, the thing is that I want to set an icon made purely by css as the background of te div "pagewrap", I can't seem to know to do it by myself so I would like you to help me out with this. I will post the link for a clearer view : http://i60.tinypic.com/312bc0p.png
Here's the HTML:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<link rel="stylesheet" type="text/css" href="css/style.css">
<link href="css/media-queries.css" rel="stylesheet" type="text/css">
<title>Insert title here</title>
</head>
<body>
<!-- ### Page Wrap ### -->
<div id="pagewrap">
<!-- ### Logo Bar ### -->
<div id="logoBar">
<div class="helper">
<div class="logo"></div>
</div>
</div>
<div style="clear:both;"></div>
<!-- ### Home Icon ### -->
<div class="icon">
<div class="home"></div>
<div class="chimney"></div>
</div>
<!-- ### Side Bar ### -->
<div id="sidebar">
<div class="widget">
<ul>
<li style="border-top:0 !important;">Acceuil</li>
<li>Identification</li>
<li>Mon Parcours</li>
<li>Ma Formation</li>
<li>Mes Projets</li>
<li>Dossier de Veille</li>
<li>Contact Me</li>
</ul>
</div>
</div>
<!-- ### Content ### -->
<div class="contenu">
<div class="post clearfix">
<h1 class="post-title">Acceuil</h1>
<br/><p>Ici vous trouverez toutes les informations conçernant moi, mes études, mes projets et ma formation.</p>
</div>
</div>
</div>
</body>
</html>
Here's the css:
/************************************************************************************
STRUCTURE
*************************************************************************************/
#pagewrap {
width: 1000px;
margin: 0 auto;
background:#3c3c3c;
height:100vh;
min-height:610px;
/*SHADOW*/
-webkit-box-shadow: 0 3px 3px 0px rgba(0,0,0,.4);
-moz-box-shadow: 0 3px 3px 0px rgba(0,0,0,.4);
box-shadow: 0 3px 3px 0px rgba(0,0,0,.4);
}
/* Home */
div.icon div.home {
height: 0px;
width: 0px;
border-width: 16px;
border-style: solid;
border-color: transparent transparent #333 transparent;
position: absolute;
bottom: 16px;
left: 0;
}
div.icon div.home:after {
content: '';
width: 5px;
height: 16px;
background-color: transparent;
position: absolute;
top: 16px;
right: -11px;
border-left: 8px solid #333;
border-right: 8px solid #333;
}
div.icon div.home:before {
content: '';
width: 9px;
height: 6px;
background-color: #333;
position: absolute;
top: 16px;
right: -5px;
}
div.icon div.chimney {
width: 4px;
height: 10px;
background: #333;
position: absolute;
right: 6px;
top: 3px;
}
/************************************************************************************
MENU
*************************************************************************************/
/**Side Bar**/
#sidebar {
width: 250px;
margin: 10px 30px 0 24px;
}
.widget {
background: #f5f5f5;
margin: 0 0 30px;
padding: 10px 20px;
/* rounded corner */
-webkit-border-radius: 8px;
-moz-border-radius: 8px;
border-radius: 8px;
/* box shadow */
-webkit-box-shadow: 0 1px 3px rgba(0,0,0,.4);
-moz-box-shadow: 0 1px 3px rgba(0,0,0,.4);
box-shadow: 0 1px 3px rgba(0,0,0,.4);
}
.widget ul {
margin: 0;
padding: 0;
}
.widget li {
margin: 0;
padding: 12px 0;
list-style: none;
clear: both;
border-top: solid 1px black;
}
.widget ul li a{
font-family:stainy;
font-size:21pt;
color:#303438;
}
.widget ul li a:hover{
text-decoration: none;
outline: none;
color:#30c9e0;
font-size:22pt;
}
.widgettitle{
font-family:stainy;
font-size:20pt;
}

What's the hard part? just add background-image for your #pagewrap and tweek the positioning and repeating should be enough.
#pagewrap {
background-image: url('YOUR_ICON');
...
}
Also check this document: https://developer.mozilla.org/en-US/docs/Web/CSS/background

Related

HTML/CSS Fieldset Legend hidden

I have two Fieldsets on my HTML page and unfortunately the Legends are getting hidden. We have an X-UA-Compatible tag that can not be removed...
Please help!
Screenshot showing hidden legends==>
Desired Result Screenshot==>
Here is code
<!DOCTYPE html>
<html dir="rtl">
<head>
<META content=IE=EmulateIE7 http-equiv=X-UA-Compatible>
<title></title>
<style>
.GBX_WITH_TITLE {
border-top: 3px solid #777777;
filter: progid:DXImageTransform.Microsoft.gradient(startColorStr='#ffffff', EndColorStr='#efefef');
}
.GBX_WITH_TITLE .DFGUIGBX {
/*margin: 0px 3px 0px 3px !important;*/
position: absolute !important;
top: -13px !important;
/*border-top: 1px solid #777777 !important;*/
padding: 0 5px 5px 5px;
color: #ffffff;
background: #777777;
display: inline;
}
</style>
</head>
<BODY>
<FIELDSET id=searchoption1 class=GBX_WITH_TITLE style="HEIGHT: 116px; WIDTH: 979px; POSITION: absolute; LEFT: 8px; TOP: 74px;">
<LEGEND id=searchoption1Legend class="DFGUIGBX" align=right VALIGN="TOP">Search Options 1
</LEGEND>
</FIELDSET>
<FIELDSET id=searchoption2 class=GBX_WITH_TITLE style="HEIGHT: 116px; WIDTH: 979px; POSITION: absolute; LEFT: 8px; TOP: 190px;">
<div><LEGEND id=searchoption2Legend class="DFGUIGBX" align=right VALIGN="TOP">Search Options 2
</LEGEND></div>
</FIELDSET>
</BODY>
</html>
Add below this code in your css Hope It will Work Perfectly.
.GBX_WITH_TITLE { overflow:visible }

How to get rid of white space at the bottom of the page

I'm coding my first website as a favor and there's some unwanted white space at the bottom that won't go away.
I've checked all the usual solutions like giving the body & footer heights, and setting bottom margins & padding to 0 but they don't seem to be working.
Could somebody please take a look at the code (linked below) and let me know what I'm doing wrong?
https://jsfiddle.net/cshotter/s9k1w6z7/
CSS
<!DOCTYPE html>
<html>
<head>
<title>Quality Precast Concepts</title>
<meta charset="utf-8" />
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style type="text/css">
body {
margin: 0 auto;
padding: 0;
font-family: Helvetica, Arial, sans-serif;
background-color: #EEEEEE;
}
a:link {
color: #111111;
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
.break {
clear: both;
}
#container {
width: auto;
}
#header {
width: 100%;
height: 163px;
color: #FFFFFF;
background-color: #DDDDDD;
}
.fixedwidthheader {
width: 1000px;
background-color: #D2691E;
margin: 0 auto;
border-top: 1px solid black;
border-left: 1px solid black;
border-right: 1px solid black;
box-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
height: auto;
}
.fixedwidthbody {
width: 1000px;
background-color: #EEEEEE;
margin: 0 auto;
border-left: 1px solid black;
border-right: 1px solid black;
box-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
height: auto;
}
.fixedwidthfooter {
width: 1000px;
background-color: #D2691E;
margin: 0 auto;
border-left: 1px solid black;
border-right: 1px solid black;
border-bottom: 1px solid black;
box-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
height: auto;
}
#toplogodiv {
float: left;
padding-top: 10px;
padding-left: 10px;
margin: 0 auto;
}
#toplogodiv img {
height: 120px;
}
#headercontactinfo {
width: 300px;
text-align: right;
float: right;
position: relative;
top: 46px;
margin: 0 auto;
font-size: 1.1em;
}
#headercontactinfo p {
padding-right: 10px;
}
#headermenudiv {
position: relative;
top: 9px;
left: -1px;
}
#headermenudiv ul {
background-color: #333333;
padding: 0;
margin: 0;
height: 20px
}
#headermenudiv li {
list-style: none;
font-size: 0.8em;
float: left;
padding: 0px 10px 0 10px;
border-right: 1px solid #D2691E;
background-color: none;
margin-top: 3px;
}
#midsection {
color: #333333;
width: auto;
background-color: #DDDDDD;
}
#midsection img {
width: 1000px;
height: 360px;
box-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 1px black;
}
#maincontent {
padding: 10px 0 20px 10px;
background-color: #EEEEEE;
position: relative;
top: -24px;
}
.list {
padding-left: 10px;
}
#frontpagemap {
padding: 0;
margin: 0;
float: right;
position: relative;
top: -310px;
left: -50px;
}
#base {
background-color: #DDDDDD;
width: 100%;
height: 160px;
color: white;
}
#footer {
height: 65px;
}
#footer img {
position: relative;
top: -30px;
left: 10px;
width: 140px;
}
#footercontact {
float: right;
position: relative;
top: -8px;
left: -10px;
}
#designtag {
float: left;
height: 20px;
}
</style>
</head>
HTML
<body >
<div id="container">
<div id="header">
<div class="fixedwidthheader" id="border">
<div id="toplogodiv">
<img src="images/logo.png">
</div>
<div id="headercontactinfo">
<p>03 347 4768</p>
<p>sales#qualityprecast.co.nz</p>
</div>
<div class="break"></div>
<div id="headermenudiv">
<div class="fixedwidthheader">
<ul>
<li>Home</li>
<li>Products</li>
<li>Projects</li>
<li>About Us</li>
<li>The Team</li>
<li>Contact Us</li>
</ul>
</div>
</div>
</div>
</div>
<div class="break"></div>
<div id="midsection">
<div class="fixedwidthbody">
<img src="images/header.jpg">
<div id="maincontent">
<h1>Welcome to Quality Precast Concepts</h1>
<h3>Quality Precast & Prestressed Concrete made in Christchurch</h3>
<p>We are a Canterbury born and bred company located on Christchurch’s doorstep – Rolleston. Our aim is to be the supplier of choice for high quality precast & prestressed products. Because of our locastion and adaptable set-up, we are able offer an extensive and complete range of manufacturing and product options to meet your precast concrete needs.</p>
<p>Our areas of expertise include:</p>
<p class="list"><strong>Prestressed</strong></p>
<ul>
<li>Unispan</li>
<li>Flat Slab</li>
<li>Interspan (rib & infill system)</li>
<li>Double Tees</li>
<li>Hollow Core</li>
</ul>
<p class="list"><strong>Precast</strong></p>
<ul>
<li>Tilt Slab Panels</li>
<li>Beams</li>
<li>Columns</li>
<li>Spandrels</li>
<li>Bleachers</li>
<li>Stairs & Landings</li>
</ul>
<div id="frontpagemap">
<iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d2889.8448452950684!2d172.3751009160351!3d-43.58894799364694!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x6d32033a1f3d6193%3A0xa416fb59f65b7fab!2s889+Jones+Rd%2C+Rolleston+7675!5e0!3m2!1sen!2snz!4v1450467163060" width="400" height="300" frameborder="0" style="border:0" allowfullscreen></iframe>
</div>
</div>
</div>
</div>
<div id="base">
<div class="fixedwidthfooter">
<div id="footer">
<img src="images/logo.png">
<div id="footercontact">
<p>Contact us today | 03 347 4768 | sales#qualityprecast.co.nz</p>
<p>889 Jones Road, Rolleston, Christchurch</p>
</div>
<div id="designtag">
Website by CSWeb-Design
</div>
</div>
</div>
</div>
</div>
</body>
</html>
It has to do with the map styles that you've included. You're doing some positioning on frontpagemap that is causing the extra whitespace.
#frontpagemap {
padding: 0;
margin: 0;
float: right;
position: relative;
top: -310px;
left: -50px;
}
Basically, when you do position: relative; the element takes the space that it would normally take up, but you just kind of made it look like it was up higher with top: -310px. It still, technically, takes up the space that it normally took up.
A quick fix would be to use margin-top instead. Which will actually move the element and the space it is taking up, as opposed to just making it appear as though it was positioned up higher.
Your footer is smaller than the footer's container. That's why there's empty space.
Either remove the height:160px from #base or add a position:relative to it, then position:absolute; bottom:0px to .fixedwidthfooter (both have slightly different results).
You're setting the 'base' height to 160px. No need, try getting rid of that.
You need to remove height from the base class
#base {
background-color: #DDDDDD;
width: 100%;
/*height: 160px;*/
color: white;
}
I have updated jsfiddle to show a way to remove the whitespace from the bottom.
I made two changes to the css. I changed the #base height to auto and I changed the height of the .footer img to 20px. You will of course want to use a height for the image that is appropriate. The point I wanted to illustrate is that part of the issue is that the image height is pushing things down.
Please mark this as the accepted answer if it fixes your issue.

Images Moving Onto Next Line But Text Is Not

I have two different sections with exactly the same CSS code but if you look at the image below, you can see at the width the screen is set to, that the images are all already moved onto a new line (which is what I want) but the categories underneath are still on the same line and get more "squashed" together. How can I make it so the categories move onto a new line like the images do? Thanks in advance.
Image of problem - http://i.imgur.com/u6GnTa1.png
HTML:
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title>Lakeside Books</title>
<link rel="stylesheet" type="text/css" href="masterstyle.css">
<meta name="viewsize" content="width-device-width,initial-scale=1.0">
<!--[if IE]>
<script type="text/javascript" src="_http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body>
<div id="wrapper">
<div id="sidebar">
<nav id="nav">
<h3 id="welcometext">Welcome To<br>Lakeside Books</h3>
<div id="searchbar">
<form action="http://www.example.com/search.php">
<input type="text" name="search" placeholder=" ...Search Book Title" class="searchstyle"/>
</form>
</div>
<ul>
<li style="background-color: #333">
<a href="1Index.html" class="link">
Home
</a>
</li>
<li>
<a href="2Catgeories.html" class="link">
Categories
</a>
</li>
<li>
<a href="http://example.com" class="link">
Bestsellers
</a>
</li>
<li>
<a href="http://example.com" class="link">
Find Us
</a>
</li>
<li>
<a href="http://example.com" class="link">
Contact
</a>
</li>
</ul>
</nav>
</div>
<div id="sectionone">
<div id="containerone">
<div id="header">
<div id="logo">
<h1>LAKESIDE BOOKS</h1>
<p>KERRYS LOCAL BOOKSTORE</p>
</div>
</div>
</div>
</div>
<div id="sectiontwo">
<div id="containertwo">
<h2 class="sectionhead">Best Selling Books</h2>
<div id="bestsellerimages">
<figure>
<img src="Images/4.jpg" alt="book1" height="200" width="131" class="imgbot">
<figcaption>The Girl On The Train <br>
<span style="font-style: italic; font-size: 0.9em">Paula Hawkins</span></figcaption>
</figure>
<figure>
<img src="Images/3.jpg" alt="book2" height="200" width="131" class="imgbot">
<figcaption>Meet Me In Manhattan <br>
<span style="font-style: italic; font-size: 0.9em">Claudia Carroll</span></figcaption>
</figure>
<figure>
<img src="Images/5.jpg" alt="book1" height="200" width="131" class="imgbot">
<figcaption>The Pointless Book 2 <br>
<span style="font-style: italic; font-size: 0.9em">Alfie Deyes</span></figcaption>
</figure>
</div>
<h3 class="secfooter">Mere Bestsellers <span style="color: #ed786a;"><strong>Here</strong></span></h3>
</div>
</div>
<div id="sectionthree">
<div id="containerthree">
<h2 class="sectionhead">Popular Categories</h2>
<div class="categories">
<h3>Fiction</h3>
<p>New Releases</p>
<p>Australian Fiction</p>
<p>Crime & Mystery</p>
<p>Childrens</p>
<p>Fantasy</p>
</div>
<div class="categories">
<h3>Fiction</h3>
<p>New Releases</p>
<p>Australian Fiction</p>
<p>Crime & Mystery</p>
<p>Childrens</p>
<p>Fantasy</p>
</div>
<div class="categories">
<h3>Fiction</h3>
<p>New Releases</p>
<p>Australian Fiction</p>
<p>Crime & Mystery</p>
<p>Childrens</p>
<p>Fantasy</p>
</div>
</div>
</div>
</div>
</body>
</html>
CSS:
html, body { /* ### */
margin:0;
padding:0;
height:100%;
width:100%;
}
body {
background-color: #fdfdfd;
font-family: Arial, "Open Sans", sans-serif-light, sans-serif, "Segoe UI";
}
#wrapper {
width: 100%;
height: 100%;
margin:0 0 0 20%; /* ### */
}
#sidebar {
background-color: #212528;
position: fixed;
width: 20%;
height: 100%;
top: 0;
left: 0;
overflow: hidden;
text-shadow: 0.1em 0.1em 0 rgba(0, 0, 0, 0.1);
}
#nav {
color: #DADADA;
display: block;
max-width: 100%;
}
#nav ul {
padding-left: 0;
}
#nav li {
list-style-type: none;
margin: 0;
padding: 0.75em 0 0.75em 0;
text-align: center;
max-width: 100%;
}
#nav li:hover {
background:#333;
}
#nav li a {
display: block;
padding: 0.5em 0;
}
.link {
text-align: right;
margin-right: 25%;
letter-spacing: 1px;
display: block;
}
a:link, a:visited, a:hover, a:active{
color: #DADADA;
text-decoration: none;
}
#welcometext {
text-align: center;
/*font-style: italic;*/
text-transform: uppercase;
font-size: 1em;
margin-top: 2em;
}
#searchbar {
width: 70%;
margin-left: auto;
margin-right: auto;
padding: 1em 1em 0.5em 1em;
text-align: right;
}
#searchbar .searchstyle{
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;
}
#searchbar input {
max-width: 95%;
}
#sectionone {
/*position: fixed;*/
top: 0;
right: 0;
width: 80%;
}
#containerone {
margin-top: 0;
width: 80%;
height: 100%;
margin-left: auto;
margin-right: auto;
text-align: center;
border-bottom: 2px solid #DADADA;
box-shadow: inset 0 -6px 0 0 #fdfdfd, inset 0 -8px 0 0 #DADADA;
}
#header {
margin: 6em 0 6em 0;
}
#logo h1 {
color: #ed786a;
text-shadow: 0.1em 0.1em 0 rgba(0, 0, 0, 0.1);
letter-spacing: 13px;
}
#logo p {
margin-top: -0.6em;
color: #888888;
letter-spacing: 4px;
font-size: 0.85em;
}
#sectiontwo {
width: 80%;
top: 0;
right: 0;
}
#containertwo {
width: 80%;
height: 100%;
margin-left: auto;
margin-right: auto;
text-align: center;
color: #888888;
padding: 0 0 2em 0;
border-bottom: 2px solid #DADADA;
box-shadow: inset 0 -6px 0 0 #fdfdfd, inset 0 -8px 0 0 #DADADA;
}
.sectionhead{
margin: 2em 0 2em 0;
color: #888888;
text-shadow: 0.1em 0.1em 0 rgba(0, 0, 0, 0.1);
}
#bestsellerimages{
float: left;
display: inline-block;
width: 100%;
max-width: 100%;
margin: 0 0 2em 0;
}
#bestsellerimages img{
padding: 0;
}
#bestsellerimages figure{
display: inline-block;
width: 131px;
}
#bestsellerimages figcaption{
font-size: 1.2em;
}
#bestsellerimages figure .imgbot{
margin: 0 0 0.5em 0;
}
#sectionthree {
width: 80%;
top: 0;
right: 0;
}
#containerthree {
width: 80%;
height: 100%;
margin-left: auto;
margin-right: auto;
text-align: center;
color: #888888;
padding: 0 0 2em 0;
border-bottom: 2px solid #DADADA;
box-shadow: inset 0 -6px 0 0 #fdfdfd, inset 0 -8px 0 0 #DADADA;
}
.secfooter{
color: #888888;
letter-spacing: 2px;
font-size: 0.85em;
}
.categories{
max-width: 100%;
width: 20%;
padding: 0 1em 0 1em;
display: inline-block;
}
The issue is that your categories divs are set to width: 20% with display: inline-block causing them to remain in columns. First, if you want them to stack on top of each other you either change the width to 100% and/or display to block:
.categories{
display: block;
width: 100%;
}
This will affect the design on desktop so if you're building this responsively you would actually just add:
#media only screen and (max-width: 568px) {
.categories{
display: block;
width: 100%;
}
}

Dropdown menu position of the submenu

I tryed to create a simple dropdown menu, but i dont get it...
I looked at some tutorials now and the position of the submenu is crap. I want a "normal" dropdown menu nothing special. The problem is maybe the position absolute, but in the tutorial he used it too. The Dropdown menu is at the secound point (Produkte). Here is my Page: Page and the Code:
*{
padding: 0px;
margin: 0px;
font-family: Raleway;
line-height: 20px;
color: #003399;
}
body{
background-image: url(images/hintergrund.png);
}
section{
margin-top: 50px;
width: 1100px;
background: white;
border: 2px solid black;
box-shadow: 8px 8px 10px 0px rgba(0,0,0,0.75);
margin-left: auto;
margin-right: auto;
padding: 20px;
background-color: #fcb774;
}
article{
width: 100%;
}
article:after{
content: '';
display: block;
clear: both;
}
.bild{
height: 200px;
width: 200px;
float: left;
border: 2px solid black;
box-shadow: 8px 8px 10px 0px rgba(0,0,0,0.75);
overflow: hidden;
}
.bild:hover{
cursor:pointer;
}
.text{
float: right;
width: 860px;
word-wrap: break-word;
height: 200px;
border: 2px solid black;
box-shadow: 8px 8px 10px 0px rgba(0,0,0,0.75);
background-color: white;
}
hr{
margin-top: 50px;
margin-bottom: 50px;
border: 1px solid black;
}
nav{
width: 100%;
}
nav ul{
background-color: #fcb774;
margin: 0px;
padding: 0px;
text-align: center;
font-size: 0;
border-bottom: 2px solid black;
box-shadow: 8px 8px 10px 0px rgba(0,0,0,0.75);
}
nav ul li{
display: inline-block;
font-size: 16px;
}
nav ul li a{
display: block;
padding: 10px 20px 10px 20px;
transition: all 0.5s;
text-decoration: none;
}
nav ul li a:hover{
background-color: white;
text-decoration: underline;
}
.dropdown{
display:none;
position: absolute;
top: 30px;
left: 0;
width: 100px;
}
nav ul li:hover .dropdown{
display: block;
}
<html>
<head>
<title>Homepage</title>
<link rel="stylesheet" href="index.css">
<link href='http://fonts.googleapis.com/css?family=Raleway:600' rel='stylesheet' type='text/css'>
<!-- include jQuery library -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>
<!-- include Cycle plugin -->
<script type="text/javascript" src="http://malsup.github.com/jquery.cycle.all.js"></script>
<script type="text/javascript">
$(document).ready(function() {
$('.slide1').cycle({
fx: 'fade',
next: '.slide1',
timeout: 0
});
})
$(document).ready(function() {
$('.slide2').cycle({
fx: 'fade',
next: '.slide2',
timeout: 0
});
});
$(document).ready(function() {
$('.slide3').cycle({
fx: 'fade',
next: '.slide3',
timeout: 0
});
});
</script>
</head>
<body>
<nav>
<ul>
<li>Startseite</li>
<li>Produkte
<ul class="dropdown">
<li><a>T-Shirts</a></li>
<li><a>Ansteckbuttons</a></li>
<li><a>SexToys</a></li>
</ul>
</li>
<li>Kontakt</li>
</ul>
</nav>
<section>
<article>
<div class="bild slide1">
<img src="images/tshirt1.png" width="200" height="200" />
<img src="images/tshirt2.png" width="200" height="200" />
</div>
<div class="text">
<h1>T-Shirts</h1>
</div>
</article>
<hr>
<article>
<div class="bild slide2">
<img src="images/tshirt3.png" width="200" height="200" />
<img src="images/tshirt4.png" width="200" height="200" />
</div>
<div class="text">
<h1>T-Shirts</h1>
</div>
</article>
<hr>
<article>
<div class="bild slide3">
<img src="images/tshirt3.png" width="200" height="200" />
<img src="images/tshirt4.png" width="200" height="200" />
</div>
<div class="text">
<h1>T-Shirts</h1>
</div>
</article>
</section>
</body>
</html>
Using position: absolute removes the element from the flow of the document and by nature becomes relative to the document. You need to contain the submenu in it's parent by using position: relative. Add that to your parent li like so:
nav ul li {
display: inline-block;
font-size: 16px;
position: relative; //add
}
FIDDLE

html column styling and border css

what i have in the code:
wrapper div outemost which in css i made to width of auto so all the inner divs have to align
inside my container div which inside of wrapper container div contains both sidebars which should be same height. Instead they don't do this and Im not sure why. Instead of having two sidebars I would like to keep the right sidebar and strect the content from the left sidebar from the left to the right sidebar.
Another major problem is that the right sidebar keeps overflowing its text and when i tried overflow:hidden it just hid evrything outside of the sidebar div which isn't what I want
here is jsfiddle so you can better see it. I want to stop overflowing on the right sidebar
and when the left sidebar is width to touch the right sidebar then under the content of the leftsidebar is where i want the buttons becuase they go out the screen when I widen the width.
http://jsfiddle.net/b6bW4/
<!DOCTYPE html>
<html lang="en">
<html>
<title>Building Blocks to Html</title>
<head>
<SCRIPT language=JavaScript>
var updated = document.lastModified document.write("Last modified: " + updated)
</script>
<script src="start.js"></script>
<meta name="keywords" content="HTML, Hyper Text Markup Language, />
<meta name="description" content="HTML in easy steps. Introductory tutorial for beginners." / >
<meta name="author" content="Miguel Castaneda" />
<meta charset="UTF-8">
<meta name="robots" content="all, nofollow" />
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="-1">
</head>
<body>
<div id="wrapper">
<!-- wrapper holds everything should be auto -->
<div id="mod"></div>
<!-- end of mod -->
<center>
<a name="top"></center>
<center>
Bottom
</center>
<div id="mainmenu">
<ul>
<li>
Home
</li>
<!-- 5 table spacing links//-->
<li>
HTML
</li>
<li>
Python
</li>
<li>
Widgets
</li>
<li>
Contact Us
</li>
</ul>
</div>
<!-- end of mainmenu -->
<div id="container">
//container holds content and sidebar
<div id="sidebar">
<p>HELLLLLLLLLLLEEEwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwMwwwwwwwwwwwwwwwwwwwwwwwwwEwwwwwwawawakdjadjlkajdlk;asmdksm.a</p>
</div>
<!-- end of sidebar -->
<div id="content">
<p >
<!-- browser picks first one in array if not in cpu then goes to 2nd font //-->
<tt>
Programmer: Miguel Castaneda(iSten23)
<br>
</br>
Head First HTML5 Programming
<br>
</br>
THIS SITE IS FOR EXPERIMENTAL PURPOSES, IS NOT INTENDED FOR COMMERCIAL PURPOSES.
</p>
</tt>
</div>
<!-- end of content -->
</div>
<!-- end of containeer-->
<center>
Top
<div id="leftrightB" >
<UL id="ul-list">
<li>
<a id="rightB"href="basic5.html" class="addborder" >
<img src="arrow1.png" height="40" width="40" alt="Link to next page">
</a>
</li>
<li>
<a id="leftB"href="basic7.html" class="addborder">
<img src="arrow.png" height="40" width="40" alt="Link to next page">
</a>
</li>
</ul>
</div>
<!--end of leftrightB -->
<div id="footermenu">
<ul>
<li>
Home
</li>
<!-- 5 table spacing links//-->
<li>
HTML
</li>
<li>
Python
</li>
<li>
Widgets
</li>
<li>
Contact Us
</li>
</ul>
</div>
<!-- END OF FOOTERMENU -->
<a name="bottom"></div>
<!-- END OF WRAPPER-->
</body>
<style>
#ul-list li {
}
a:hover {
color: #00f000;
text-shadow: 0px 2px green;
}
.addborder:hover {
border: 1px solid #000000;
}
#sidebar {
position: absolute;
right: 0;
margin-top: 2px;
background-color: #8cc63f;
border-top: 1px solid #fff;
border-bottom: 1px solid #fff;
font-size: 10px;
line-height: 1;
padding: 0px 5px 0px 5px;
width: 10%;
height: 480px;
background-image: radial-gradient(hsla(0, 0%, 87%, 0.31) 9px, transparent 10px), repeating-radial-gradient(hsla(0, 0%, 87%, 0.31) 0, hsla(0, 0%, 87%, 0.31) 4px, transparent 5px, transparent 20px, hsla(0, 0%, 87%, 0.31) 21px, hsla(0, 0%, 87%, 0.31) 25px, transparent 26px, transparent 50px);
background-size: 30px 30px, 90px 90px;
background-position: 0 0;
<!-- //white-space: nowrap;
//overflow: hidden;
//word-wrap: break-word -->
}
#wrapper {
width: auto;
}
#content {
position: absolute;
left: 0;
background-color: #8cc63f;
border-top: 1px solid #fff;
border-bottom: 1px solid #fff;
font-size: 10px;
line-height: 1;
padding: 0px 5px 0px 5px;
width: 10%;
height: 480px;
}
<!-- img {
border-width: 1px;
border-color: Black;
}
--> .table {
display: table;
<!-- Allow the centering to work */ --> margin: 0 auto;
}
ul#ul-list {
min-width: 696px;
list-style: none;
padding-top: 20px;
}
ul#ul-list li {
display: inline;
}
#mainmenu {
width: auto;
height: 35px;
font-size: 16px;
font-family: Tahoma, Geneva, sans-serif;
font-weight: bold;
text-align: center;
text-shadow: 3px 2px 3px #333333;
background-color: #8AD9FF;
border-radius: 8px;
position: absolute;
top: 50px;
left: 0;
right: 0;
margin-left: 0;
margin-right: 0;
}
#mainmenu ul {
height: auto;
padding: 8px 0px;
margin: 0px;
}
#mainmenu li {
display: inline;
padding: 20px;
}
#mainmenu a {
text-decoration: none;
color: #00F;
padding: 8px 8px 8px 8px;
}
#mainmenu a:hover {
color: #F90;
background-color: #FFF;
}
#footermenu {
width: auto;
height: 35px;
font-size: 16px;
font-family: Tahoma, Geneva, sans-serif;
font-weight: bold;
text-align: center;
text-shadow: 3px 2px 3px #333333;
background-color: #52D7E5;
//main color of the menu border-radius: 8px;
position: absolute;
bottom: 0px;
left: 0;
right: 0;
margin-left: 0;
margin-right: 0;
}
#footermenu ul {
height: auto;
padding: 8px 0px;
margin: 0px;
}
#footermenu li {
display: inline;
padding: 20px;
}
#footermenu a {
text-decoration: none;
color: #00F;
// padding: 8px 8px 8px 8px;
}
#footermenu a:hover {
color: #F90;
background-color: #17861A;
//color of gover over iterm
}
rightleftB {
display: table-cell vertical-align: bottom;
}
#wrapper {
width: 100%;
}
</style>
</html>
I think you need this...
Result
body{
overflow: hidden;
}