473,657 Members | 2,624 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

float widths

Is in theory creating layout of two floats possible, where

the left "float:left " has fixed with
the right "float:left " extends to the right side of the browser window?
Jul 21 '05 #1
5 1905
On Tue, 19 Oct 2004 14:04:12 +0300, Marek Mänd <ca********@mai l.ee> wrote:
Is in theory creating layout of two floats possible, where

the left "float:left " has fixed with
the right "float:left " extends to the right side of the browser window?


If the second element is to extend all the way across the browser window
why bother floating it at all? Why not just give it a margin-left
equivalent to the width of the first float?

#one {float: left; width: 20em;}
#two {margin-left: 20em;}

If you really want to float both of them then you'll need to specify the
widths in percentages:

#one {float: left; width: 20%;}
#two {float: left; width: 80%;}

(and watch out for the box model bugs)

Steve
Jul 21 '05 #2
Steve Pugh wrote:
On Tue, 19 Oct 2004 14:04:12 +0300, Marek Mänd <ca********@mai l.ee> wrote:
If you really want to float both of them then you'll need to specify
the widths in percentages:
#one {float: left; width: 20%;}
#two {float: left; width: 80%;}
(and watch out for the box model bugs)


no possibility to use for example width:200px on #one ?
(very probably not and thatswhy table layouting is still the best )
Jul 21 '05 #3
On Tue, 19 Oct 2004 16:29:08 +0300, Marek Mänd <ca********@mai l.ee> wrote:

no possibility to use for example width:200px on #one ?
Sure just change 20em in my first example to 200px.
Presumably, your first element only contains images and that's why a fixed
pixel width is desirable?
(very probably not and thatswhy table layouting is still the best )


Rubbish.

Steve

Jul 21 '05 #4
Marek Mänd <ca********@mai l.ee> wrote in message news:<2t******* ******@uni-berlin.de>...
Is in theory creating layout of two floats possible, where

the left "float:left " has fixed with
the right "float:left " extends to the right side of the browser window?


most browsers will not be happy with this, but there are many
alternatives to achieve the same effect, e.g. making the right div
absolute with its "left" attribute chosen properly, or relative with
"padding" chosen properly. I think both will work.

Tony
Jul 21 '05 #5
Marek Mänd wrote:
no possibility to use for example width:200px on #one ? (very
probably not and thatswhy table layouting is still the best )


That's the second time you've made this silly claim, apparently based
only on your inability to create css layouts.

I'm starting to wonder if you're just trolling for a fight on CSS v.
table layouts. Why not just simulate an argument by reading the
archives? It's been debated to death, and I imagine most of the regulars
don't care to rehast the debate.

--
Brian (remove "invalid" to email me)
Jul 21 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
15031
by: Jeff Thies | last post by:
I have a series of blocks that are float left that I need centered on the page. <div class="center" align="center"> <div style="width: 100 px;float: left">thumbnail 1</div> <div style="width: 100 px;float: left">thumbnail 2</div> <div style="width: 100 px;float: left">thumbnail 3</div> </div>
4
3010
by: Aaron Robson | last post by:
Hi about 1% of my clients use macs, and I've spent an inordinate amount of time trying to get things working on them... I've validated my html and css - the html has 5 errors (strict), all due to asp.net. I don't believe these to be the problem (missing type='text/javascript' and that sort of thing). The site works fine in NS7.1 and IE6, and has done so when i used transitional and strict doctypes. It is currently strict.
5
2297
by: Chris Beall | last post by:
See http://pages.prodigy.net/chris_beall/BeallSprings/WC.Deed%20GG.116-17.html using the CSS at http://pages.prodigy.net/chris_beall/BeallSprings/BSstyle.css The page is a transcript of a deed. I'm trying to retain, somewhat, the layout of the original document. Below the deed are the signatures (on the right) and the names of witnesses (on the left), hence paired blocks of text.
16
2612
by: Wolfgang Meier | last post by:
Hi, Although it might seem like I am firing out random posts in quick succession this matter is indeed one I thought about for quite some time without coming to a conclusion: Why is it that most professional CSS authors prefer /float/ing elements over elements held in place by /position/? Given, for example, the following layout...
20
2685
by: Joe exCSSive | last post by:
Hi, folks: I'm back...and now I'm really stuck !! I have a graphic ( http://www.sundialontario.com/images/makeitatable.jpg ) that I would like to convert to CSS and I'm not sure how to do this.
2
2436
by: krsgoss | last post by:
I'm trying to do a two column "form" layout based on article here: http://www.alistapart.com/stories/practicalcss/ The idea is to have a label, and a value using definition list markup. I float the dt left, and the dd right with fixed widths for each. This works fine in both IE and FF until I have a <br> elements within the dd elements. IE does not clear subsequent dt's, and they are not floated beneath the multiline dd element,...
2
2178
by: Midsomer | last post by:
Hi. I have an Access database with a form containing 4 datasheets and I allow the user to change column widths. On closing the form, a routine is fired that saves each column width to an INI file. When the form is opened, the INI file is read and sets up the column widths for the user. Works well, but there is a slight delay on closing the form, so I would like to detect if any column widths have been changed and save them only if...
6
5676
by: Ira Gladnick | last post by:
The following displays as expected in IE7 (div2 floats to the right of div1). But in Firefox, div2 appears below div1. Why exactly does this happen in Firefox, and how to make it work as expected? &lt;body style="width:400px"&gt; &lt;div id="div1" style="float:left"&gt; div 1 stuff &lt;/div&gt;
2
3999
by: James Harris | last post by:
I'm trying to make sense of the standard C data sizes for floating point numbers. I guess the standards were written to accommodate some particular floating point engines that were popular at one time but I can only find references to the number of decimals etc. Basically, if I wanted to specify C-sized reals in a language that only accepted bit- widths, e.g. float(exponent 8, mantissa 24) I'm looking for what numbers would be needed...
0
8407
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8319
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8739
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8612
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6175
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5638
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4329
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1969
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1732
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.