Languages: English • 日本語 (Add your language)
Display the full, anchored URL to a single comment. This function must be used within the comments loop.
If you want to link to all of the comments for an entry, use the function comments_link() instead.
<?php comment_link() ?>
None.
Create an anchored permalink to a single comment:
<a href="<?php comment_link(); ?>">Permalink to this comment</a>
The code shown above will result (depending on your permalink settings) in something like this:
<a href="http://example.com/2009/07/15/example-post/comment-page-1/#comment-3">Permalink to this comment</a>
Since: 1.5.0
comment_link() is located in wp-includes/feed.php
.