Line Break problem

Discussion in 'HTML & Website Design' started by squishi, Feb 5, 2010.

  1. #1
    I have a simple input element of type image that should be placed to the right of a text.
    Here is the code:
    <th align="left">ID
    <form action="index.php" method="post"><input type="image" src="/img/icons/bullet_arrow_ASC.png" value="DESC" alt="" name="sorting" /></form>
    </th>
    Code (markup):
    No matter what I try, the image always shows up below the "ID" text.
    I have already tried to remove all the blank spaces between the text and the input tag.
    I've also made sure that the form or the input field do not have any margins or paddings that could cause a line break.

    How could I format the input to show to the right of the "ID" text?
     
    squishi, Feb 5, 2010 IP
  2. krsix

    krsix Peon

    Messages:
    435
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #2
    place "ID" inside the form.

    <th align="left"><form action="index.php" method="post">ID <input type="image" src="/img/icons/bullet_arrow_ASC.png" value="DESC" alt="" name="sorting" /></form></th>
     
    krsix, Feb 5, 2010 IP
  3. squishi

    squishi Peon

    Messages:
    58
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    You were right about that. Thanks.
    It was the form tag that caused the line break.
     
    squishi, Feb 5, 2010 IP