WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Found this code in the WP Codex but not sure how to use it to remove the hyperlink and/or date from comments.

delete_comment_meta( $comment_id, $meta_key, $meta_value );
share|improve this question
Are you talking about changing how it's displayed on your site? Or actually destroying that part of the comment's data? – GhostToast Jun 6 '13 at 17:42
removing the date from all comments or removing the link in the date. – Haymanpl Jun 6 '13 at 18:45

Check if your theme has its own comment template by going to [yoursite.com]/wp-admin/theme-editor.php (when logged in as an administrator). Then look at the right column and try to find comments.php file. If it's there, it controls the way your comments are displayed, so you can manually delete hyperlinks and dates from it.

If you can't find date printed out in comments.php, go to functions.php and try to find it there (search for functions containing word "comments"). Try to find get_comment_date() or get_comment_time().

And before you delete any line of code - always backup the content of the files.

share|improve this answer

I don 't want to edit the core files. Its poor practice and the changes will be over ridden when i update.

I need a custom function for this which i can use in my child theme.

share|improve this answer

Your Answer


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.