Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8617189
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T05:47:49+00:00 2026-06-12T05:47:49+00:00

Using CSS, is it possible to right-align two DIVs? I have a title and

  • 0

Using CSS, is it possible to right-align two DIVs?

I have a title and I want to right-align a more link underneath it. The site is internal and so, unfortunately, IE7 is the primary browser. (We will upgrade to IE8 before the end of the year, and some are using Chrome). I’d like to avoid javascript, but I’m open to it.

The title changes, so absolute widths won’t work. It should look something like this:

| Arbitrarily long title text
|                     more...

I’ve been all over the Googles looking for a solution, but everything I’ve found so far relates to right-aliging the content of a DIV, or to right-aligning a DIV to the page, or right-aligning a DIV within an absolutely sized DIV.

I can show you my efforts so far, but as none of them work, I don’t think they’re of much use.

<html>
    <body>

        <div style="float:left;">
            Arbitrarily long title
            <div style="float:right">more...</div>
        </div>

        <div style="width:0px; overflow:visible; white-space:nowrap;">
            Arbitrarily long title
            <div style="float:right">more...</div>
        </div>

        <!-- This sort of simulates what I want, but the title length is arbitrary and I don't want to have to measure the text -->
        <div style="width:120px;">
            Arbitrarily long title
            <div style="float:right">more...</div>
        </div>

    </body>
</html>

If anyone knows of a duplicate question, I’d love to learn the secrets of your Google-fu!

EDIT
Image, as requested. The link is bordered with red. (I had to set the margin-left to 70px to achieve this affect.)

enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T05:47:51+00:00Added an answer on June 12, 2026 at 5:47 am

    Another way you might solve it (I don’t have IE here, so I can’t test it now, but I used similar styling on cross browser before).

    Snippet

    .title-block {
      float: left;
      position: relative;
      padding-bottom: 1em;
    }
    
    .more {
      position: absolute;
      right: 0;
      bottom: 0;
    }
    
    ​
    <div class="title-block">
      <div>Arbitrarily long title</div>
      <div class="more">more...</div>
    </div>​
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is it possible when using css to make text align right next to a
is it possible using jQuery and CSS to split a div in two, and
Is it possible to make cross browser rendering site without using CSS reset? Is
I have a feeling that this probably is not possible using strictly CSS, but,
I have a drop down menu using CSS only. I want the drop down
Possible Duplicate: Offset a background image from the right using CSS CSS usually is
Is it possible using CSS background-position: to position an image to the far right
Using CSS how is it possible to have a horizontal list and have all
Possible Duplicate: Can I have multiple background images using CSS? Is it possible to
I'm getting more into jQuery and so have set up a HTML/Javascript/CSS base site

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.