Tell me more ×
WordPress Answers is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

My page in question is here.

I have tried to add a comments.php to my custom theme so I can remove the website field and so I could edit the default values of the fields and remove the labels. When I add a comments.php all of my comments disappear and the comments are no longer functional. I have no idea how to make these modifications.

I've tried editing comments-template.php but removing the field in that file doesn't remove it from the site, I am assuming because it is already in the database.

I am new to PHP so any details on how I can get these text fields edited would be great.

share|improve this question
You might get help with this and this. If you are not having a comment.php, you can create one. – Rohit Pande Jan 17 at 10:11
If you create a blank comments.php, WordPress supposes that it has nothing to do there. Try inserting the code from the twentytwelve theme, and modify it. – fischi Jan 17 at 10:35

1 Answer

There are multiple solutions for your question.

  1. Using the CSS trick

    Use #commentform .comment-form-url {display:none;} for not displaying the website field.

  2. Commenting the code

    look in your theme's comments.php for a line like or similar to:

    <p><input type="text" name="url" id="url" value="<?php echo esc_attr($comment_author_url); ?>" size="22" tabindex="3" /> <label for="url"><small>Website</small></label></p>

comment it out or delete it

p.s. always back up file 1st before edit.

3.Use following tutorial

Wordpress How To Remove The Website Field From The Comment Form

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.