WordPress.org

Ready to get started?Download WordPress

Forums

Editing comments template? (8 posts)

  1. LeLLow
    Member
    Posted 7 years ago #

    I've been giving it some thought and decided to have my interaction section with the comments form, so entries could automatically be put in instead of emailed to me.

    My comments form is big and I was just wondering how I can set the width to my liking? And which file is it to set the width?

    I used the wp auto installer from my host. Using fantastico. So I'm unsure which file it is.

    Hope to hear from someone. Thank you.

  2. wiziology
    Member
    Posted 7 years ago #

    first... do you have a link to the page?

    second... you are going to have to login to your admin dashboard and find out which template you are using. Once in there, click on the presentation menu and then theme editor. On the right side of the page should be a list of the templates pages - click the page you want to edit.

    I dont know if you want to edit the comment form itself or the way the comments are displayed, so that will be a factor.

    Once I know which one you actually mean, I could help more, but for right now, ill let you know this:

    To change the width of the comments being displayed, go to the style.css file and change

    .commentlist {
    width: (the desired width you want)px;
    }

    if you want to change the textbox where the user can type comments, edit this:

    #comment {
    width: (the desired width you want)px;
    }

  3. LeLLow
    Member
    Posted 7 years ago #

    Thank you :)

    Just one more question, how can I make it with 2 background colors? Here's an example and can better explain what I mean [ http://oh-rihanna.com/index.php/2007/05/21/uk-good-girl-gone-bad-bonues-disc/#comments ]

    U see how one comment would be a certain color and the next is different? *ugh* I hope I'm making sense and not confusing anyone.

    But if you know what I mean, can you tell me how I can do that?

    Thank you :)

  4. Saska
    Member
    Posted 6 years ago #

    I second that. How do i edit the way the comments are displayed, ie get rid of the centration?

    Should I edit the template/name/comments.php file?

  5. Kafkaesqui

    Posted 6 years ago #

    Not sure what 'centration' is meant to refer to here, but if you're asking how to alternate colors or whatnot on comments, it's an oft asked question:

    http://wordpress.org/search/alternate+comment+colors?forums=1

  6. Saska
    Member
    Posted 6 years ago #

    Not really. I want to modify the comment template. For example, right now, all comments are centered, I want them to be left aligned like the rest of the text. The author name is displayed at the bottom of the comment, I want it on the top etc etc. How do I change those kind of things? It can't be done in the css I assume, so there has to be a template for it somewhere, and I guess it might be the comments.php file? I tried to browse through it, but all the PHP scared me ...

  7. Kafkaesqui

    Posted 6 years ago #

    Well it's typically done in both the css and the template's HTML, which is comments.php for a theme. If a theme does not have that template, WordPress uses the default theme's comments.php (if that's the case, you can copy the default theme's comments template to your active theme's directory).

    Can't help with the issue of PHP fright, but a couple steps can help allay some of your fears:

    1. Make backup copies of any templates before editing them.

    2. http://codex.wordpress.org/Blog_Design_and_Layout

  8. Saska
    Member
    Posted 6 years ago #

    I've been experimenting with the style.css and the comments.php but there is one thing I just can't modify, how do I decrease the space between these two:
    http://img149.imageshack.us/img149/4570/sampleeeeeeeegd7.jpg

    <?php comment_text() ?>
    and

    <li id="comment-<?php comment_ID() ?>">
    <cite><?php comment_type(__('Comment'), __('Trackback'), __('Pingback')); ?> <?php _e('by'); 
    
    ?> <?php comment_author_link() ?> — <?php comment_date() ?> @ <a href="#comment-<?php 
    
    comment_ID() ?>"><?php comment_time() ?></a></cite> <?php edit_comment_link(__("Edit This"), ' |'); ?>

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.