Full Width Areas With Sidebar
How do I make an full width areas with sidebar?
What is a full width areas with sidebar? How do you make a full width areas with sidebar? This script and codes were developed by Keith Wyland on 13 September 2022, Tuesday.
Full Width Areas With Sidebar - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Full Width Areas With Sidebar</title> <script src="https://s.codepen.io/assets/libs/modernizr.js" type="text/javascript"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <style> /* NOTE: The styles were added inline because Prefixfree needs access to your styles and they must be inlined if they are on local disk! */ body, html { overflow-x: hidden;
}
h1 { color: white;
}
.wrapper { background-color: #cccccc; width: 75%; margin: 1em auto; padding: 0 2em 2em;
}
.wrapper:before,
.wrapper:after { content: " "; display: table;
}
.wrapper:after { clear: both;
}
.wrapper { *zoom: 1;
}
.content-wrapper { float: left; width: 60%;
}
.content1, .content2 { margin: 1em 0 1em; background-color: #5eabed; padding: 1em; color: white;
}
.content2 { background-color: #5ead06;
}
.sidebar { background-color: #deba65; padding: 1em; width: 30%; float: right; color: white;
}
.break-width { padding-left: 2000px; padding-right: 2000px; margin-left: -2000px; margin-right: -2000px; width: 100%;
} </style> <script src="https://cdnjs.cloudflare.com/ajax/libs/prefixfree/1.0.7/prefixfree.min.js"></script>
</head>
<body> <!--based on this: https://css-tricks.com/full-browser-width-bars/#li-comment-94090 -->
<div class="wrapper"> <h1>Full Width Areas With Sidebar</h1> <div class="content-wrapper "> <div class="content1 break-width"> <p>Might be an old problem that's been solved years ago...</p> </div> <div class="content2 break-width"> <p>But I came across it in a recent design given to me and I also needed to support IE7/Compat Mode (yes, that's <em>still</em> a thing in some places).</p> <p>And the design involved a sidebar, which I hadn't seen in the other solutions. Well, I didn't really do much searching because I figured it would be faster to apply what I already learned and tweak it from there.</p> </div> </div> <aside class="sidebar"> <p>Here's the sidebar part. It needed to be next to the areas that extend, so obviously that was a bit of an issue.</p> <p>Luckily, the solution described at the link below pretty much worked, I just needed to wrap the extending areas in their own wrapper and float that instead of floating the individual extending areas. Then float the sidebar and tada!</p> <p><a href="https://css-tricks.com/full-browser-width-bars/#li-comment-94090">Based on this</a></p> </aside>
</div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script>
</body>
</html>
Full Width Areas With Sidebar - Script Codes CSS Codes
body, html { overflow-x: hidden;
}
h1 { color: white;
}
.wrapper { background-color: #cccccc; width: 75%; margin: 1em auto; padding: 0 2em 2em;
}
.wrapper:before,
.wrapper:after { content: " "; display: table;
}
.wrapper:after { clear: both;
}
.wrapper { *zoom: 1;
}
.content-wrapper { float: left; width: 60%;
}
.content1, .content2 { margin: 1em 0 1em; background-color: #5eabed; padding: 1em; color: white;
}
.content2 { background-color: #5ead06;
}
.sidebar { background-color: #deba65; padding: 1em; width: 30%; float: right; color: white;
}
.break-width { padding-left: 2000px; padding-right: 2000px; margin-left: -2000px; margin-right: -2000px; width: 100%;
}
Developer | Keith Wyland |
Username | keithwyland |
Uploaded | September 13, 2022 |
Rating | 3.5 |
Size | 2,709 Kb |
Views | 26,312 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
Check ... to CodePen | 3,286 Kb |
Eagle Tooth | 2,934 Kb |
CSS Drawers | 67,859 Kb |
Signal | 2,125 Kb |
Testing a Sass Mixin | 2,291 Kb |
Learning Flexbox via flexbox.io | 2,342 Kb |
Order-changing Sidebar | 4,100 Kb |
Tunnel | 1,983 Kb |
SO example | 2,195 Kb |
Radio Button A11y Q | 3,521 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
Underlined form fields | Mitchdot | 2,323 Kb |
Image Hover | Johnheiner | 3,409 Kb |
Scoreboard.js basic usage | Tbleckert | 1,733 Kb |
Slide In Panel | Vikvarg | 2,811 Kb |
Flex Chart | James_zedd | 4,111 Kb |
Basic HTML Slideshow | Tomhodgins | 3,386 Kb |
Animated css matrix type | NielsOeltjen | 3,484 Kb |
A Pen by Anoop | Anoopjohn | 330,760 Kb |
Drag and Drop Quiz | Cgspicer | 3,837 Kb |
CSS Colors | Alexpate | 2,232 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!