Languages: English • 日本語 中文(简体) • (Add your language)
Displays a link to edit the current post, if a user is logged in and allowed to edit the post. Can be used within The Loop or outside of it. If outside the loop, you'll need to pass the post ID. Can be used with pages, posts, attachments, and revisions.
Use get_edit_post_link to retrieve the url.
<?php edit_post_link( $link, $before, $after, $id, $class ); ?>
__('Edit This')
Displays edit post link using defaults.
<?php edit_post_link(); ?>
Displays edit post link, with link text "edit", in a paragraph (<p>) tag.
<?php edit_post_link('edit', '<p>', '</p>'); ?>
edit_post_link() is located in wp-includes/link-template.php
Edit Link: edit_post_link(), edit_comment_link(), edit_tag_link(), edit_bookmark_link()