get_post_format_link

The timeline below displays how wordpress function get_post_format_link has changed across different WordPress versions. If a version is not listed, refer to the next available version below.

WordPress Version: 4.3

/**
 * Returns a link to a post format index.
 *
 * @since 3.1.0
 *
 * @param string $format The post format slug.
 * @return string|WP_Error|false The post format term link.
 */
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);
}

WordPress Version: 3.7

/**
 * Returns a link to a post format index.
 *
 * @since 3.1.0
 *
 * @param string $format The post format slug.
 * @return string The post format term link.
 */
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);
}