edit_bookmark_link

Definition:
function edit_bookmark_link( $link = '', $before = '', $after = '', $bookmark = null ) {}

Display edit bookmark (literally a URL external to blog) link anchor content.

Parameters

  • string $link: Optional. Anchor text.
  • string $before: Optional. Display before edit link.
  • string $after: Optional. Display after edit link.
  • int $bookmark: Optional. Bookmark ID.

Defined filters

  • edit_bookmark_link
    apply_filters( 'edit_bookmark_link', $link, $bookmark->link_id )

Source code

function edit_bookmark_link( $link = '', $before = '', $after = '', $bookmark = null ) {

	$bookmark = get_bookmark($bookmark);



	if ( !current_user_can('manage_links') )

		return;



	if ( empty($link) )

		$link = __('Edit This');



	$link = '<a href="' . get_edit_bookmark_link( $bookmark ) . '" title="' . esc_attr__( 'Edit Link' ) . '">' . $link . '</a>';

	echo $before . apply_filters( 'edit_bookmark_link', $link, $bookmark->link_id ) . $after;

}

994

No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: