1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

vertical div alignment

Discussion in 'HTML & Website Design' started by sandrodz, Apr 21, 2007.

  1. #1
    I have a vertical div alignment, http://www.flunkme.com/college-guide/

    Basically I have: - Full Article (707 words)
    - Posted in Grants & Loans

    I want to show them on the same line, one aligned left the other right.

    Code for the first one is:

     
    sandrodz, Apr 21, 2007 IP
  2. SHARKTICUS

    SHARKTICUS Peon

    Messages:
    39
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I don't quite follow, maybe it is because it is the weekend and my brain is slowing down.....
     
    SHARKTICUS, Apr 21, 2007 IP
  3. pixel_dust

    pixel_dust Peon

    Messages:
    151
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #3
    this should work:


    vanessa.
     
    pixel_dust, Apr 21, 2007 IP
  4. sandrodz

    sandrodz Peon

    Messages:
    1,482
    Likes Received:
    29
    Best Answers:
    0
    Trophy Points:
    0
    #4
    :( it messed up whole style...
     
    sandrodz, Apr 21, 2007 IP
  5. pixel_dust

    pixel_dust Peon

    Messages:
    151
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #5
    is it a liquid layout?
    do you want one aligned waaaay left and one waaay right or beside each other?


    vanessa.
     
    pixel_dust, Apr 21, 2007 IP
  6. sandrodz

    sandrodz Peon

    Messages:
    1,482
    Likes Received:
    29
    Best Answers:
    0
    Trophy Points:
    0
    #6
    I'm not sure what u mean under liquid, its based upon default wordpress theme.

    Actually I wanted to try both and see how it looks. :)
     
    sandrodz, Apr 21, 2007 IP
  7. SHARKTICUS

    SHARKTICUS Peon

    Messages:
    39
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Why don't you just keep it simple and use a table?

    
    <center>
      <table cellspacing="2" cellpadding="0" border="0">
        <tr>
          <td>
            <div class="entry">
              <?php the_content('Read the rest of this entry &raquo;'); ?>
            </div>
          </td>
          <td>
            <div class="postmetadata">
               Posted in <?php the_category(', ') ?>
            </div>
          </td>
        </tr>
      </table>
    </center>
    
    Code (markup):
     
    SHARKTICUS, Apr 21, 2007 IP
  8. sandrodz

    sandrodz Peon

    Messages:
    1,482
    Likes Received:
    29
    Best Answers:
    0
    Trophy Points:
    0
    #8
    I don't like tables... I'd like to accomplish this using divs
     
    sandrodz, Apr 21, 2007 IP
  9. pixel_dust

    pixel_dust Peon

    Messages:
    151
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #9
    I'm looking at the page now
    it looks like you'll have to fiddle around with the css stylesheet to get what you want

    first thing is to take out the .postmetadata where it clears it left
    that's why it's pushing down below the entry div
    but you might also have to fiddle around with the entry and postmetadata margins and padding to get the exact look you're after

    hth,


    vanessa.
     
    pixel_dust, Apr 21, 2007 IP
    sandrodz likes this.
  10. ajsa52

    ajsa52 Well-Known Member

    Messages:
    3,426
    Likes Received:
    125
    Best Answers:
    0
    Trophy Points:
    160
    #10
    For two lines:

    
    <div class="entry" style="text-align: left;">
    <?php the_content('Read the rest of this entry &raquo;'); ?>
    </div>
    
    <div class="postmetadata" style="text-align: right;">
    Posted in <?php the_category(', ') ?>
    </div>
    
    Code (markup):
    For one line:

    
    <div>
      <span class="entry" style="text-align: left;">
      <?php the_content('Read the rest of this entry &raquo;'); ?>
      </span>
    
      <span class="postmetadata" style="text-align: right;">
      Posted in <?php the_category(', ') ?>
      </span>
    </div>
    
    Code (markup):
     
    ajsa52, Apr 21, 2007 IP
    sandrodz likes this.