Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS CSS3 & HTML5 – figcaption under floated image with wrap text problem

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #35680
    MBM
    Participant

    I have floated an image and used the figcaption tag to add text under it but the text is not aligned correctly. How do I position the text under the image while wrapping the body text to the left of the image?

    This is the class to float the image :


    .imagel {
    margin-top: 20px;
    margin-left: 20px;
    float:right;
    font-size: 16pt;
    color: #FFFF00;
    }

    And the html to caption the image :



    Spartacus
    Andy Whitfield as Spartacus

    And the result

    #92904
    TheDoc
    Member

    First, you don’t seem to have the opening

    tag. You’ll want to float the entire figure tag, like this: http://jsfiddle.net/HPCYm/

    #92924
    jnrhrn
    Member

    its simple.. dont set width or hight to img tag…

    #92930
    MBM
    Participant

    Thanks Doc.

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘CSS’ is closed to new topics and replies.