Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Software Development
Programming
Programming Q&A
HTML CSS help for assignment
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="StanleyDev" data-source="post: 328546" data-attributes="member: 9151"><p>I'm trying to create a template for my assignment before I start making the webpages, and Im currently stuck, When I insert multiple content box's my sidebar moves down, I'm not sure how to fix this, with just one content box it's fine, but when I insert more the sidebar shifts down.</p><p></p><p>The HTML:</p><p>[HTML]<!DOCTYPE html></p><p><html></p><p> <head></p><p> <title>Home</title></p><p> <link rel="stylesheet" href="css/normalize.css"></p><p> <link rel="stylesheet" href="css/sitecss.css"></p><p> </head></p><p></p><p> <body></p><p> <!-- nav bar code --></p><p> <nav class="nav"></p><p> <a class="zenitLink" href="#">My Zenit Account</a>|</p><p> <a class="home" href="#">Home</a> |</p><p> <a class="imgGal" href="#">Photo Gallery</a> |</p><p> <a class="video" href="#"> Video</a> |</p><p> <a class="audio" href="#">Audio</a> |</p><p> <a class="html5" href="#">HTML5</a> |</p><p> <a class="tblCSS" href="#">Tables with CSS</a> |</p><p> <a class="forms" href="#">Forms</a> |</p><p> <a class="cssUsed" href="#">CSS Used</a> |</p><p> <a class="extra" href="#">Extra</a></p><p> </nav></p><p> <!-- end of nav bar code --></p><p> <!-- content --></p><p> <div id="mainContent"></p><p> <h3>HTML5 & CSS Normalize</h3></p><p> <p>testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test test</p></p><p> </div></p><p> <div id="secondaryContent"></p><p> <h3>HTML5 & CSS Normalize</h3></p><p> <p>testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test test</p></p><p> </div></p><p> <!-- end of content --></p><p> <!-- side Bar code code --></p><p> <aside id="sideBar"></p><p> <p>testtest testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test test</p></p><p> </aside></p><p> <!-- end of side bar code --></p><p> <!-- social media bar --></p><p> <aside id="socialMedia"></p><p> <center><img src="images/social-media.png"></center> </p><p> </aside></p><p> <!-- end of social media bar --></p><p> </body></p><p></html>[/HTML]</p><p></p><p>The CSS:</p><p>[CODE]body{</p><p> background-color: #A0D8F1;</p><p> padding: 0px;</p><p> width: 1280px;</p><p>}</p><p></p><p>.nav{</p><p> /*background-image: url(../images/navBG.png);*/</p><p> background-color: #0A224E;</p><p> color: white;</p><p> font-family: Tahoma, Geneva, sans-serif;</p><p> margin: 0px;</p><p> padding-top: 20px;</p><p> width: 1280px;</p><p> height: 40px;</p><p></p><p>}</p><p></p><p>.zenitLink{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.home{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.imgGal{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.video{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.audio{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.html5{</p><p> color: white;</p><p> padding: 20px;</p><p>}</p><p></p><p>.tblCSS{</p><p> color: white;</p><p> padding: 20px;</p><p>}</p><p></p><p>.forms{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.cssUsed{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p>.extra{</p><p> color: white;</p><p> padding: 20px;</p><p></p><p>}</p><p></p><p></p><p>#sideBar {</p><p> width: 280px;</p><p> height: auto ;</p><p> float: right;</p><p> padding-bottom: 15px;</p><p> padding-top: 15px;</p><p> background-color: #BF381A;</p><p></p><p>}</p><p></p><p>#sideBar p{</p><p> margin-top: 16px;</p><p> height: auto;</p><p> margin-bottom: 16px;</p><p> text-align: center;</p><p> padding-left: 10px;</p><p> padding-right: 10px;</p><p></p><p>}</p><p></p><p>#socialMedia{</p><p> width: 280px;</p><p> height: auto;</p><p> float: right;</p><p> clear: both;</p><p> </p><p> background-color: #E07628;</p><p></p><p> }</p><p>#socialMedia img{</p><p> margin-top: 30px;</p><p> margin-bottom: 30px;</p><p> margin-left: 15px;</p><p> margin-right: 15px;</p><p></p><p>}</p><p></p><p>#mainContent{</p><p> width: 980px;</p><p> float: left;</p><p> clear: both;</p><p> background-color: #E9AF32;</p><p> margin-left: 10px;</p><p> margin-top: 30px;</p><p> clear: both;</p><p></p><p>}</p><p></p><p>#mainContent h3, p{</p><p> padding-left: 10px;</p><p> padding-right: 10px;</p><p></p><p>}</p><p></p><p>#secondaryContent{</p><p> width: 980px;</p><p> float: left;</p><p> clear: both;</p><p> background-color: #E9AF32;</p><p> margin-left: 10px;</p><p>}</p><p></p><p>#secondaryContent h3, p{</p><p> padding-left: 10px;</p><p></p><p>}[/CODE]</p></blockquote><p></p>
[QUOTE="StanleyDev, post: 328546, member: 9151"] I'm trying to create a template for my assignment before I start making the webpages, and Im currently stuck, When I insert multiple content box's my sidebar moves down, I'm not sure how to fix this, with just one content box it's fine, but when I insert more the sidebar shifts down. The HTML: [HTML]<!DOCTYPE html> <html> <head> <title>Home</title> <link rel="stylesheet" href="css/normalize.css"> <link rel="stylesheet" href="css/sitecss.css"> </head> <body> <!-- nav bar code --> <nav class="nav"> <a class="zenitLink" href="#">My Zenit Account</a>| <a class="home" href="#">Home</a> | <a class="imgGal" href="#">Photo Gallery</a> | <a class="video" href="#"> Video</a> | <a class="audio" href="#">Audio</a> | <a class="html5" href="#">HTML5</a> | <a class="tblCSS" href="#">Tables with CSS</a> | <a class="forms" href="#">Forms</a> | <a class="cssUsed" href="#">CSS Used</a> | <a class="extra" href="#">Extra</a> </nav> <!-- end of nav bar code --> <!-- content --> <div id="mainContent"> <h3>HTML5 & CSS Normalize</h3> <p>testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test test</p> </div> <div id="secondaryContent"> <h3>HTML5 & CSS Normalize</h3> <p>testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test testtest test test test</p> </div> <!-- end of content --> <!-- side Bar code code --> <aside id="sideBar"> <p>testtest testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test testttest test test testtest test test testtest test test test</p> </aside> <!-- end of side bar code --> <!-- social media bar --> <aside id="socialMedia"> <center><img src="images/social-media.png"></center> </aside> <!-- end of social media bar --> </body> </html>[/HTML] The CSS: [CODE]body{ background-color: #A0D8F1; padding: 0px; width: 1280px; } .nav{ /*background-image: url(../images/navBG.png);*/ background-color: #0A224E; color: white; font-family: Tahoma, Geneva, sans-serif; margin: 0px; padding-top: 20px; width: 1280px; height: 40px; } .zenitLink{ color: white; padding: 20px; } .home{ color: white; padding: 20px; } .imgGal{ color: white; padding: 20px; } .video{ color: white; padding: 20px; } .audio{ color: white; padding: 20px; } .html5{ color: white; padding: 20px; } .tblCSS{ color: white; padding: 20px; } .forms{ color: white; padding: 20px; } .cssUsed{ color: white; padding: 20px; } .extra{ color: white; padding: 20px; } #sideBar { width: 280px; height: auto ; float: right; padding-bottom: 15px; padding-top: 15px; background-color: #BF381A; } #sideBar p{ margin-top: 16px; height: auto; margin-bottom: 16px; text-align: center; padding-left: 10px; padding-right: 10px; } #socialMedia{ width: 280px; height: auto; float: right; clear: both; background-color: #E07628; } #socialMedia img{ margin-top: 30px; margin-bottom: 30px; margin-left: 15px; margin-right: 15px; } #mainContent{ width: 980px; float: left; clear: both; background-color: #E9AF32; margin-left: 10px; margin-top: 30px; clear: both; } #mainContent h3, p{ padding-left: 10px; padding-right: 10px; } #secondaryContent{ width: 980px; float: left; clear: both; background-color: #E9AF32; margin-left: 10px; } #secondaryContent h3, p{ padding-left: 10px; }[/CODE] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Software Development
Programming
Programming Q&A
HTML CSS help for assignment
Top