I have problem with sectioning my page. I need my page to have 2sections like a newspaper on left and right sides both independent. what should do? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

I have problem with sectioning my page. I need my page to have 2sections like a newspaper on left and right sides both independent. what should do?

9th Jun 2016, 1:37 PM
OLIVER BARAZA MAKUNDA
OLIVER BARAZA MAKUNDA - avatar
5 Answers
+ 5
As Alexandre said, then make them float:left; Use margins to control spacing between them. You should wrap both columns in a div if you want them centered. Here's an example (adjust measurement as you like): <style> #wrapper { margin: 0 auto; /* Center */ padding-top: 25px; width: 80%; } #col1 { width: 45%; float: left; } #col2 { width: 45%; float: left; margin-left: 45px; } #footer { clear: left; width 100%; } </style> <body> <div id="wrapper"> <div id="col1"> ..content.. </div> <div id="col2"> ..content.. </div> <div id="footer> ..content.. </div> </div><!--wrapper end--> </body>
9th Jun 2016, 11:35 PM
ZinC
ZinC - avatar
+ 2
but it is mentioned in lesson that div is replaced with other tags like article section then why at you using it
29th Jun 2016, 8:21 AM
Kurapati Praveen
Kurapati Praveen - avatar
+ 1
thanks
10th Jun 2016, 10:27 AM
OLIVER BARAZA MAKUNDA
OLIVER BARAZA MAKUNDA - avatar
0
You should use <div> tags for the two different main areas.
9th Jun 2016, 8:51 PM
Alexandre Palma
Alexandre Palma - avatar
0
use frame to divide ur page to numbers of pages on one sheet
1st Aug 2016, 3:45 AM
Daliah Aljutayli-داليه الجطيلي
Daliah Aljutayli-داليه الجطيلي - avatar