Solved

Elements not floating next to one another, despite adequate space

Posted on 2013-06-28
3
208 Views
Last Modified: 2013-06-28
Test page:
http://partnersdesign.net/test

Please click "Partners Design, Inc." at the top. The block with the gray, yellow, blue and green backgrounds should be aligning to the right of the red background. It looks like there is enough space. This was working previously, but I messed something up. I am having trouble seeing what is wrong, I would really appreciate another set of eyes.

HTML:

<ul id="nav2" class="nomobile">
			<li id="nav2bt1" class="nav2hl">ABOUT</li>
			<li id="nav2bt2">PARTNERS</li>
			<li id="nav2bt3">AWARDS</li>
			<li id="nav2bt4">STUDIO</li>
		</ul>

		<div id="contentarea1" class="contentarea">
			<div class="contentquotetag nomobile">01.<br />
				LAURETTA DIVES<br />
				Owner<br />
				<i>The Picture Desk</i></div>
			<div class="contentquote nomobile clearfix">
				<i>&ldquo;The branding has been extremely successful and, although it was created some years back, we have not felt the need to update it significantly, as the look is so classic.&rdquo;</i>
			</div>

			<img class="closebutton yesmobile" src="img/gr_x.png" border="0" />

			<h3>WHO BETTER TO START A GREAT PARTNERSHIP THAN IDENTICAL TWIN BROTHERS?</h3>

			<p>text...</p>
		</div>

Open in new window


CSS:

ul#nav2{float:left;margin:0;padding:12.6em 0 0 0;background-color:#c00;}
ul#nav2 li{display:block;width:116px;height:26px;margin:0;padding:4px 0 0 36px;font-family:'alternate_gothic_fs_no_2Rg',Arial,Helvetica,sans-serif;font-size:1.3em;letter-spacing:1px;cursor:pointer;}
ul#nav2 li.nav2hl{background:transparent url('../img/gr_btbg.png') no-repeat top left;}
ul#nav2 li.nav2mouseover{background:transparent url('../img/gr_btbg.png') no-repeat top left;}

div.contentquote{width:530px;height:7em;padding:1em 40px 9px 24px;margin:0 0 3em -1em;background:transparent url('../img/gr_quotebg.png') no-repeat top left;color:#000;font-size:1.1em;line-height:2;text-indent:-0.5em;background-color:#00c;}
div.contentquotetag{float:right;margin-top:2.3em;font-size:0.7em;line-height:1.6;text-indent:0;width:156px;letter-spacing:1px;background-color:#0c0;}

div.contentarea{float:right;width:52em;margin:0 10em 0 0;background-color:#ccc;}

Open in new window


Thank you!
0
Comment
Question by:bbdesign
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 22

Accepted Solution

by:
Kim Walker earned 500 total points
ID: 39284131
The 10em right margin for class contentarea is pushing contentarea1 away from the right side. (Line 222 of main.css) You need to either remove that margin or set contentarea1 to zero right margin.
0
 
LVL 57

Expert Comment

by:Julian Hansen
ID: 39284148
main.css line 222 is where the problem is
div.contentarea {
  background-color: #CCCCCC;
  float: right;
  margin: 0 10em 0 0;
  width: 52em; /* <=== TOO MUCH HERE */
}

Open in new window


em is proportional so you might have changed something higher up the hierarchy which caused the div to be wider.
0
 

Author Comment

by:bbdesign
ID: 39284256
Ah, thank you so much!
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Using Specialized Fonts in CSS 1 61
CSS Style 8 52
CSS Won't Show Up On Drupal Omega Sub-Theme 1 36
Displaying Text in Columns in HTML 3 32
Creating a CSS block that only applies to printing By default, all of your CSS applies to every possible view of your page - whether on screen, printed, landscape, touch-screen, or whatever.  You can, however, add CSS that only applies under certai…
This is a how to build your own CSS3 slideshow and when I say CSS3 I mean just CSS with no javascript in sight! There a few examples online of how to do this but most just show you an example without any explanation, others make it more complicat…
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
In this tutorial viewers will learn how to style different bullet points for unordered lists in CSS. Begin with a normal unordered list; the default bullet point is a solid circle: In the CSS, create a defined class of unordered list by typing "ul.S…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question