[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 238
  • Last Modified:

Why won't my labels float right?

Hi, I have labels that I would like to float up or next to the materials div:


But I can't figure out a way to make them move up (besides giving them each an absolute position.) I tried giving them a negative margin-top but that made them all appear in the same spot (over lapping).  Anyone know a way to work around this?
1 Solution
Greg AlexanderLead DeveloperCommented:
OK, just wrap all your labels a div like this:

<div style="float:left; width:300px;"></div>

Open in new window

Then, you can add a float on the materials div like this:

<div id="materials" style=" float:right;">

Open in new window

So you need a 2 column layout. At the minute the only thing with a float is iframe ... everything else will wrap onto a new line, you need to do something like this:

<div style="float:left;width:300px;">

<div id="materials" style="float:right;">
  Content here

Open in new window

FairyBusinessAuthor Commented:

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now