Quick HTML help, please respond

Discussion in 'BlackHat Lounge' started by BlackxHat, Mar 8, 2012.

  1. BlackxHat

    BlackxHat Power Member

    Joined:
    Oct 6, 2009
    Messages:
    592
    Likes Received:
    78
    I have an image and an iframe (a youtube video). How can I get them to line up side by side, next to each other. Right now the image is on the left and when I add the youtube video it shows up below the image. This is not good, how can I get it on the right side of the image?

    The way i have it now:
    Code:
    <img src="boat.gif" alt="Big Boat" />      <iframe width="560" height="315" src="http://www.youtube.com/embed/xgrcK9Ozb_Q" frameborder="0" allowfullscreen></iframe>
     
    Last edited: Mar 8, 2012
  2. voljin

    voljin Junior Member

    Joined:
    Jan 17, 2012
    Messages:
    123
    Likes Received:
    286
    Occupation:
    Witch Doctor
    Location:
    Scourge Side
    maybe set a 2 column table? left for image, right for video
     
    • Thanks Thanks x 1
  3. VanillaH

    VanillaH Regular Member

    Joined:
    Dec 23, 2009
    Messages:
    323
    Likes Received:
    266
    You put the image in a div container, the video in another div container.

    The two div containers are "float: left;"

    Code:
    <div style="float: left;"><img src="logo.png" alt="Big Boat" /></div>      <div style="float: left;"><iframe width="560" height="315" src="http://www.youtube.com/embed/xgrcK9Ozb_Q" frameborder="0" allowfullscreen></iframe></div>
     
    • Thanks Thanks x 2
    Last edited: Mar 8, 2012
  4. BlackxHat

    BlackxHat Power Member

    Joined:
    Oct 6, 2009
    Messages:
    592
    Likes Received:
    78
    can you tell me whats the whole div container code?
     
  5. VanillaH

    VanillaH Regular Member

    Joined:
    Dec 23, 2009
    Messages:
    323
    Likes Received:
    266
    That is whole code. I just tested it and it works fine.
     
    • Thanks Thanks x 1
  6. BlackxHat

    BlackxHat Power Member

    Joined:
    Oct 6, 2009
    Messages:
    592
    Likes Received:
    78
    cant see it
     
  7. VanillaH

    VanillaH Regular Member

    Joined:
    Dec 23, 2009
    Messages:
    323
    Likes Received:
    266
    Oops. Sorry. I forgot to put your image. Silly me. :D

    Code:
    <div style="float: left;"><img src="boat.gif" alt="Big  Boat" /></div>      <div style="float: left;"><iframe  width="560" height="315" src="http://www.youtube.com/embed/xgrcK9Ozb_Q"  frameborder="0" allowfullscreen></iframe></div>
     
    • Thanks Thanks x 1
  8. BlackxHat

    BlackxHat Power Member

    Joined:
    Oct 6, 2009
    Messages:
    592
    Likes Received:
    78
    thank you man