Title: Remove Required Comment Textarea
Last modified: November 6, 2017

---

# Remove Required Comment Textarea

 *  Resolved [WPAddiction](https://wordpress.org/support/users/wpaddiction/)
 * (@wpaddiction)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/remove-required-comment-textarea/)
 * Is there a way to make the comment textarea not required or remove it all together
   for a specific post type. I’ve done a bunch of digging, but I haven’t found anything
   that isn’t super hacky. It seems like there should be a function or something
   to change this. I know there are plenty of options to change the name and email
   fields, but nothing to change the actual comment field.
 * My plan is to make a kind of public video contest where users will need to be
   logged in and comments will be video links from services like YouTube or Vimeo.
   Everyone will be able to see all of the videos and vote on their favorite. I 
   would imagine that other people have done similar things with photos.
 * If there isn’t a way to remove the comment textarea (which is what I’m starting
   to think) I would at least like to be able to change the input type to a URL 
   or another creative idea if anyone has one.

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Shital Marakana](https://wordpress.org/support/users/shital-patel/)
 * (@shital-patel)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/remove-required-comment-textarea/#post-9654162)
 * **add below function in function.php for Remove Required Comment Textarea in 
   comment form**
 *     ```
       function custom_validate_comment() {
         	//make comment not required
       	if(empty($_POST['comment'])){
       		$_POST['comment'] = "empty_comment";
       	}
       }
       add_action('pre_comment_on_post', 'custom_validate_comment');
   
       function custom_change_comment( $commentdata ) {
           if( $commentdata['comment'] == 'empty_comment' )
               $commentdata['comment'] = '';
           return $commentdata;
       }
       add_filter('preprocess_comment', 'custom_change_comment');
       ```
   
 *  Thread Starter [WPAddiction](https://wordpress.org/support/users/wpaddiction/)
 * (@wpaddiction)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/remove-required-comment-textarea/#post-9658021)
 * Thanks a lot; I probably won’t have time to properly test this until Friday because
   of the day job, but I should be back here with results this weekend.
 *  Thread Starter [WPAddiction](https://wordpress.org/support/users/wpaddiction/)
 * (@wpaddiction)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/remove-required-comment-textarea/#post-9791699)
 * I haven’t spent a ton of time on this project lately, but I have done some testing
   and continue to get “ERROR: please type a comment.” Thanks for the help and I
   could be missing something, but so far I haven’t had any luck with that code.
   I don’t think it’s the theme I’m using because I just created a Twenty Fourteen
   child theme for this website. I’m hoping to work on this through the holiday 
   season so I’d still appreciate any help I can get.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Remove Required Comment Textarea’ is closed to new replies.

## Tags

 * [comment](https://wordpress.org/support/topic-tag/comment/)
 * [Comments](https://wordpress.org/support/topic-tag/comments/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 2 participants
 * Last reply from: [WPAddiction](https://wordpress.org/support/users/wpaddiction/)
 * Last activity: [8 years, 7 months ago](https://wordpress.org/support/topic/remove-required-comment-textarea/#post-9791699)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
