WordPress.org

Ready to get started?Download WordPress

Forums

Moving the labels on comments (6 posts)

  1. yeleek
    Member
    Posted 6 years ago #

    Hi,
    If you look here http://yeleek.co.uk/about/ you can see the person who wrote the theme i'm basing my own on had the labels beneath the input boxes.

    I've worked out how i can move the input boxes to the right with a margin-left: 12.5em; but how can i get the label once these boxes are moved to be on the left of the text boxes? I've been looking for ages and can't find it...
    Heres the css i think is for the comments box. Please help. Thanks

    /*comment styling*/
    /* Comments Styling */
    #commentlist li {
    margin-bottom: 1.5em;
    padding-bottom: 1em;
    border-bottom: 1px solid #700000;
    }
    
    #commentform {
    margin: 1em 0;
    background: #ffffff;
    width: 280px;
    }
    
    #commentform textarea {
    background: #f8f7f6;
    border: 1px solid #d6d3d3;
    width: 280px;
    }
    #commentform textarea:hover {
    background: #FFFFFF;
    border: 1px solid #d6d3d3;
    }
    #commentform textarea:focus {
    background: #ffffff;
    border: 1px solid #939793;
    }
    
    #commentform #email, #commentform #author, #commentform #url {
    font-size: 1.1em;
    background: #f8f7f6;
    border: 1px solid #d6d3d3;
    width: 280px;
    }
    #commentform #email:hover, #commentform #author:hover, #commentform #url:hover {
    font-size: 1.1em;
    background: #ffffff;
    border: 1px solid #d6d3d3;
    width: 280px;
    }
    #commentform #email:focus, #commentform #author:focus, #commentform #url:focus {
    font-size: 1.1em;
    background: #ffffff;
    border: 1px solid #939793;
    width: 280px;
    }
    #commentform input{
    margin-bottom: 3px;
    }
  2. SmallPotato
    Member
    Posted 6 years ago #

    Your question is confusing. First you said you figured out how to move the inputs to the right... but how can you get the labels once the those boxes are moved to the left of the text boxes?

    Try to clarify your question so we could help you.

  3. yeleek
    Member
    Posted 6 years ago #

    Hi,
    'How can you get the labels once the those boxes are moved, to the left of the text boxes' - Exactly.

    Moving the labels either to the left of the input boxes or even above them is what i'm looking to do. For some reason the author of the theme i'm using decided to put the labels beneath, and i can't find a way to move them which works.

    Thanks :)

  4. yeleek
    Member
    Posted 6 years ago #

    anyone? please?

    cheers

  5. moshu
    Member
    Posted 6 years ago #

    Hmm, another badly coded theme: the right sidebar comes before the content in the code - it just deosn't make sense and bad for SE.

    Re your question: it has NOTHING to do with the stylesheet. It is about the order of the code lines in the template file(s).
    If you have the textarea first and the label after - it will show up "later" = after. You need to edit the comments.php file: move the "label" lines above the form fields.

  6. yeleek
    Member
    Posted 6 years ago #

    Is that it?! Flipping heck...

    Many thanks Moshu!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags