get_post_format_link

Definition:
function get_post_format_link( $format ) {}

Returns a link to a post format index.

Parameters

  • string $format: Post format

Return values

returns:Link

Source code

function get_post_format_link( $format ) {

	$term = get_term_by('slug', 'post-format-' . $format, 'post_format' );

	if ( ! $term || is_wp_error( $term ) )

		return false;

	return get_term_link( $term );

}

9587

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: