Hi all,

I have a header section of my website which will have the logo on the left side 
and then on the right side will be some text and other bits and bobs. To? 
accomplish this I have done a float left on the <div id="headercontent1"> 
containing the image on the left and then a float: right on the <div 
id="headercontent2"> to the right that will contain some text. I have set 
widths to both of these so that they meet up correctly. Is this the best way to 
accomplish this? I feel that this approach can easily be broken because if div 
to the right expands it breaks the layout (i guess this is standard CSS).

The HTML markup and CSS is as follows...

*****
HTML
*****

<div id="header">
??? <div id="headercontent1">
??? ??? <asp:Image ID="imgCreditSafeLogo" CssClass="creditsafelogo" 
ImageUrl="~/images/creditsafelogo.gif" runat="Server" />
??? </div>
??? <div id="headercontent2">
??? ??? <div>
??? ??? ??? language select:
??? ??? ??? <asp:ImageButton ID="ImageButton8" runat="server" 
ImageUrl="~/Images/lu.gif"/>
??? ??? ??? <asp:ImageButton ID="ImageButton9" runat="server" 
ImageUrl="~/Images/fr.gif" />
??? ??? </div>
??? </div>
??? <div class="clear"></div>

</div>

*****
CSS
*****
#header 
{
??? background:#ddd;
}

#headercontent1
{
??? float: left;
??? width: 200px;
??? background-color: #FFF;
}

#headercontent2
{
??? float: right;
??? width: 536px;
??? height: 90px;
??? padding: 5px;
??? text-align: center;
}

.clear
{
??? clear: both;
}

Thanks and a happy new year to you all.

Tryst

________________________________________________________________________
AOL's new homepage has launched. Take a tour at http://info.aol.co.uk/homepage/ 
now.
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to