Problems with float:left float:right

This is a discussion on "Problems with float:left float:right" within the Web Page Design section. This forum, and the thread "Problems with float:left float:right are both part of the Design Your Website category.


 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices




Reply
 
LinkBack Thread Tools
  #1  
Old Nov 13th, 2006, 16:24
New Member
Join Date: Nov 2006
Location: sdakj;sdflajkl;jkl;fjkl;
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Problems with float:left float:right

Hey all,

I'm a new member here, just wanted to know a good way to layout a site in css for browser resolutions over 800 x 600 . I have made one, but when viewed in 1260 x whatever becomes completely screwed up.


=-Jo
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

  #2  
Old Nov 13th, 2006, 16:51
Most Reputable Member
Join Date: Apr 2006
Location: Cornwall, UK
Posts: 1,310
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

You need to start by thinking about whether the design of a site lends itself to a fluid width or whether it is better with a fixed width. If it's going to be a fixed width design, then you need to design for 800px wide less scrollbar etc. typically 760px max.

If you decide you are going for a fluid design then you need to structure things in such away that this flexibility doesn't break the design at certain widths.

Just to clarify a point from your question, you don't layout a site in css. you layout (structure) a site in (x)html and use css to control the 'look-n-feel' of the site.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old Nov 13th, 2006, 17:12
New Member
Join Date: Nov 2006
Location: sdakj;sdflajkl;jkl;fjkl;
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

Yeah,

I was making my design fluid with the float:left float:right clear:both. Designing 760px. How do I get it to show up on higher resolutions?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4  
Old Nov 14th, 2006, 06:58
Up'n'Coming Member
Join Date: Aug 2006
Location: Australia
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

I don't know if this will help but i just had an alignment problem with floats.
see my site www.skiaustralia.abshost.net . The floats weren't sitting next to each other when assigned these properties.
Code: Select all
#sidebar    {padding: 0 10px 10px 10px;
                   float: left;
                   width: 110px;
}

#insidemain    {width: 550px;
                        float: right;
}
so i had to put this in my html under the floats. and it fixed them up
HTML: Select all
<!-- CLEAR BOTH FLOAT. THIS IS IMPORTANT! IF YOUREMOVE THIS LINE, YOU'LL END UP SCREWING THE CONTENT AND THE SIDEBAR COLUMN -->
<div style="clear: both;">
</div>
<!-- END FLOAT CLEANER -->    
hope this will help

Last edited by Powderhound; Nov 14th, 2006 at 07:00.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5  
Old Nov 14th, 2006, 08:32
Ryan Fait's Avatar
Elite Veteran
Join Date: May 2006
Location: Las Vegas
Posts: 3,787
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

I've written an article about clearing floats. Simply clear: both; won't work in all browsers. The links at the top of this forum in the sticky.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6  
Old Nov 14th, 2006, 10:00
Up'n'Coming Member
Join Date: Aug 2006
Location: Australia
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

what browsers won't support clear: both; ?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7  
Old Nov 17th, 2006, 10:34
Ryan Fait's Avatar
Elite Veteran
Join Date: May 2006
Location: Las Vegas
Posts: 3,787
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

It's not that they don't support clear: both; it's just that they don't all see a <div> as being wide enough to cover the whole area. Sometimes just the single propery will work, but most likely not in all browsers and certainly not in all instances of its application.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #8  
Old Nov 17th, 2006, 10:35
Ryan Fait's Avatar
Elite Veteran
Join Date: May 2006
Location: Las Vegas
Posts: 3,787
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

In my opinion, clear and float are the two most misused properties in CSS.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #9  
Old Nov 17th, 2006, 21:24
Up'n'Coming Member
Join Date: Aug 2006
Location: Australia
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Problems with float:left float:right

fair enough

it works for me in IE and FF, for other browsers however, i don't know. Also i'm only fixing two divs, that may make a difference to the outcome.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
css floating

Thread Tools

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
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Float: Left with firefox magnetica Web Page Design 2 Aug 24th, 2007 16:55
difficulty with a float left and right layout konnor5092 Web Page Design 9 Aug 10th, 2007 07:01
Float problems timmytots Web Page Design 4 May 11th, 2007 14:18
help useing float building page right to left rocket468 Web Page Design 5 Jan 24th, 2007 00:56


All times are GMT. The time now is 14:09.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved