MajorGeeks Support Forums

Go Back   MajorGeeks Support Forums > ----------= PC, Desktop and Laptop Support =---------- > Software
Register FAQ Members List Calendar Casino Mark Forums Read

Software Software such as operating systems like Windows XP, Windows Vista, Windows 7 etc., or specific programs.


Reply
 
Thread Tools Display Modes
  #1  
Old 06-16-09, 03:43
georgey12345 georgey12345 is offline
Private E-2
 
Join Date: May 2009
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default CSS divs positioning question

I am designing a site with HTML and CSS. I cant position the divs correctly. Can someone tell me the correct code. Imagine 2 divs, one on the right and one the left, both of same heights. That is simple. But i would like one on the left and 3 on the right, and the height must add up back to that of the left.

Thank you so much for your help.
Reply With Quote
Sponsored links
  #2  
Old 06-16-09, 07:17
MutD's Avatar
MutD MutD is offline
Specialist
 
Join Date: Apr 2005
Posts: 307
Thanks: 1
Thanked 7 Times in 7 Posts
Default Re: CSS divs positioning question

This should do it (only tested in Firefox)

Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

<html>
  <body>

    <div style="float:left; background-color:red; width:50%; height:600px;">a</div>

    <div style="float:right;width:50%;">

      <div style="background-color:blue; height:200px;">b</div>
      <div style="background-color:yellow; height:200px;">c</div>
      <div style="background-color:green; height:200px;">d</div>
    </div>

</body>
</html>
Moving the inline styles into a css file is an exercise left for the reader
__________________
If at first you dont succeed, try, try again. Then quit. There's no point being a damn fool about it.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Question about the correct protocol to get a question answered at Major Geeks Maggie Software 16 03-26-04 12:45


All times are GMT -5. The time now is 01:51.


MajorGeeks.Com Home Page
| Admin Tools | All In One | Anti-Spyware | Anti-Virus | Appearance | Backup | Benchmarking | BIOS | Browsers | Covert Ops |
Data Recovery | Diagnostics | Drive Cleaners | Drive Utilities | Drivers | Driver Tools Ergonomics | Firewalls | Games | Game Tweaks | Graphics | Input Devices | Internet Tools | Macintosh | Mail Utilities | Memory | Messaging | Monitoring | Microsoft | Multimedia | Networking | Office Tools | Process Management | Processor | Registry | Security | System Info | Toys | Video | Miscellaneous
|
Powered by vBulletin® Version 3.8.4
Copyright © 2009 vBulletin Solutions, Inc. All rights reserved.
Ad Management by RedTyger