Results 1 to 6 of 6

Thread: CSS Layout advice

  1. #1
    Senior Member
    Join Date
    Apr 2005
    Location
    Norwich
    Posts
    261
    Thanks
    1
    Thanked
    0 times in 0 posts

    CSS Layout advice

    I need to layout a page that had previously been created using tables. i will be using only CSS.

    Here is a copy of the layout:




    I was wondering what is the best way to achieve this in CSS?

    The total width of the page is 750px (not including the two images left and right) using a page container.

    a) How do i position the two left and right images that are really outside of the main design?
    b) What about the white (which will be green) space around the content area and content boxes?

    Thanks

  2. #2
    HEXUS webmaster Steve's Avatar
    Join Date
    Nov 2003
    Posts
    14,283
    Thanks
    293
    Thanked
    841 times in 476 posts

    Re: CSS Layout advice

    Well, you could put appropriate margins around the content area and boxes. Or you could contain them within an element that's padded. As for the images, absolute positioning might work, not sure.
    PHP Code:
    $s = new signature();
    $s->sarcasm()->intellect()->font('Courier New')->display(); 

  3. #3
    Senior Member
    Join Date
    Apr 2005
    Location
    Norwich
    Posts
    261
    Thanks
    1
    Thanked
    0 times in 0 posts

    Re: CSS Layout advice

    Quote Originally Posted by Steve View Post
    Well, you could put appropriate margins around the content area and boxes. Or you could contain them within an element that's padded. As for the images, absolute positioning might work, not sure.
    I thought about that - having one large area and dividing that into the 'content' and the seperate 'content boxes' but i thought it looked a little messy.

    The images outside of the page container concern me more though, I can position them with floats and margins, but that might/will cause problems with the rest of the design.

  4. #4
    Registered+
    Join Date
    Jan 2009
    Posts
    50
    Thanks
    0
    Thanked
    5 times in 4 posts

    Re: CSS Layout advice

    Hi englishpremier,

    Here's what I would do.

    An outer wrapper called 'outerWrapper', with three columns called 'leftCol', 'centerCol', 'RightCol'

    'leftCol', contains the left image
    'rightCol', contains the right image
    'centerCol' is a wrapper for remaining items

    'centerCol' contains 'Header', 'Navigation', 'contentWrapper', 'Footer'

    'contentWrapper' contains 'Content' and 'boxWarapper'

    'boxWrapper' contains the box types

    hope that all makes sense, essentially , work your way in from the outside.

    I could knock up a simple page with css to show you if you like. I'm more a programmer than a CSS developer, but I have had had to convert some table-based designs to CSS.

  5. #5
    Custom User Title
    Join Date
    Oct 2005
    Location
    Wirral UK
    Posts
    1,168
    Thanks
    10
    Thanked
    14 times in 14 posts
    • cougarslam's system
      • Motherboard:
      • Asus Maximus Formula SE (ROG)
      • CPU:
      • Core 2 Duo E6600 @ 3ghz
      • Memory:
      • 4gb Corsair DDR2
      • Storage:
      • 1TB
      • Graphics card(s):
      • BFG Nvidia 8800GT OC 512MB
      • PSU:
      • Corsair HX520
      • Case:
      • Zorro
      • Operating System:
      • Vista Business 32
      • Monitor(s):
      • 2 x 17" crt
      • Internet:
      • adsl max (entanet)

    Re: CSS Layout advice

    strange positioning for the 2 images?

    have you got a link to the original tables based site?

  6. #6
    Senior Member
    Join Date
    Apr 2005
    Location
    Norwich
    Posts
    261
    Thanks
    1
    Thanked
    0 times in 0 posts

    Re: CSS Layout advice

    I did using the following bits of code:

    Code:
    #page-container {
    	width: 750px;
    	position: absolute;
    	left: 50%;
    	margin-left: -375px;
    	margin-top: 0px;
    	background-color:#007e3e; 
    }
    
    
    .dogleft {
    	position: absolute;
    	bottom: 100px; 
    	left: -150px;  
    	border: 0px;
    }
    
    
    .dogright {
    	position: absolute;
    	bottom: 275px; 
    	right: -150px;  
    	border: 0px;
    }
    Thanks for the offers of help though.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Suspended for 'Gross Misconduct' - Advice Please
    By psychy in forum General Discussion
    Replies: 40
    Last Post: 20-05-2010, 08:39 PM
  2. Sony Ericsson P990i/Nokia E65 Advice
    By amjedm in forum Smartphones and Tablets
    Replies: 6
    Last Post: 17-06-2008, 07:31 PM
  3. Advice on new pc
    By PCS in forum Pre-Built Laptops and Desktops
    Replies: 12
    Last Post: 30-04-2008, 08:46 PM
  4. Hmmmm, much advice needed...
    By vrykyl in forum Automotive
    Replies: 20
    Last Post: 29-02-2008, 11:18 PM
  5. Thermalright HR-03 Plus 8800 62c IDLE ?! Advice Needed
    By Pugz in forum Help! Quick Relief From Tech Headaches
    Replies: 0
    Last Post: 22-12-2007, 02:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •