Re: div



dorayme wrote on 07 mei 2011 in comp.infosystems.www.authoring.stylesheets:

In article
<ed650da2-db46-4e0a-998a-1139858131d3@xxxxxxxxxxxxxxxxxxxxxxxxxxx
m>,
cerr <ron.eggler@xxxxxxxxx> wrote:

I would like to have two divs besides each other.

.class {float: left;}

with

<div class="class">content</div>
<div class="class">content</div>

should do the trick. They get all cosy this way unless the second
one has not been given enough room for the viewport, either by
its partner or by interfering third party busybodies like
paddings, margins, borders, container widths - there is no end to
the obstacles to happy marriages.

<style type='text/css'>

..myClass {display: inline;border: green solid 1px;}

/* inline-block would be nicer, alas not for IE. */

</style>

<div class="myClass">content</div>
<div class="myClass">content</div>
<div class="myClass">content</div>
<div class="myClass">content</div>

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
.



Relevant Pages

  • Re: div
    ... cerr wrote: ... ..class {float: left;} ... should do the trick. ... They get all cosy this way unless the second ...
    (comp.infosystems.www.authoring.stylesheets)
  • Re: CComboBox-Droplist: float values?
    ... Store the float in the ... a trick, however: you can't cast a float to an LPARAM without causing ... Why not just use atof() on the strings and compare the results? ...
    (microsoft.public.vc.mfc)
  • Re: CComboBox-Droplist: float values?
    ... Store the float in the ... a trick, however: you can't cast a float to an LPARAM without causing it ... Why not just use atof() on the strings and compare the results? ...
    (microsoft.public.vc.mfc)
  • Re: References referencing array members - how evil is it?
    ... Asfand Yar Qazi wrote: ... For arguments sake, I'll test with double (using the old ... > '#define float double' trick), ...
    (comp.lang.cpp)