get_link

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

WordPress Version: 4.6

/**
 * Retrieves bookmark data based on ID.
 *
 * @since 2.0.0
 * @deprecated 2.1.0 Use get_bookmark()
 * @see get_bookmark()
 *
 * @param int    $bookmark_id ID of link
 * @param string $output      Optional. Type of output. Accepts OBJECT, ARRAY_N, or ARRAY_A.
 *                            Default OBJECT.
 * @param string $filter      Optional. How to filter the link for output. Accepts 'raw', 'edit',
 *                            'attribute', 'js', 'db', or 'display'. Default 'raw'.
 * @return object|array Bookmark object or array, depending on the type specified by `$output`.
 */
function get_link($bookmark_id, $output = OBJECT, $filter = 'raw')
{
    _deprecated_function(__FUNCTION__, '2.1.0', 'get_bookmark()');
    return get_bookmark($bookmark_id, $output, $filter);
}

WordPress Version: 4.5

/**
 * Retrieves bookmark data based on ID.
 *
 * @since 2.0.0
 * @deprecated 2.1.0 Use get_bookmark()
 * @see get_bookmark()
 *
 * @param int    $bookmark_id ID of link
 * @param string $output      Optional. Type of output. Accepts OBJECT, ARRAY_N, or ARRAY_A.
 *                            Default OBJECT.
 * @param string $filter      Optional. How to filter the link for output. Accepts 'raw', 'edit',
 *                            'attribute', 'js', 'db', or 'display'. Default 'raw'.
 * @return object|array Bookmark object or array, depending on the type specified by `$output`.
 */
function get_link($bookmark_id, $output = OBJECT, $filter = 'raw')
{
    _deprecated_function(__FUNCTION__, '2.1', 'get_bookmark()');
    return get_bookmark($bookmark_id, $output, $filter);
}

WordPress Version: 4.4

/**
 * Retrieve bookmark data based on ID.
 *
 * @since 2.0.0
 * @deprecated 2.1.0 Use get_bookmark()
 * @see get_bookmark()
 *
 * @param int $bookmark_id ID of link
 * @param string $output OBJECT, ARRAY_N, or ARRAY_A
 * @return object|array
 */
function get_link($bookmark_id, $output = OBJECT, $filter = 'raw')
{
    _deprecated_function(__FUNCTION__, '2.1', 'get_bookmark()');
    return get_bookmark($bookmark_id, $output, $filter);
}

WordPress Version: 3.7

/**
 * Retrieve bookmark data based on ID.
 *
 * @since 2.0.0
 * @deprecated 2.1.0
 * @deprecated Use get_bookmark()
 * @see get_bookmark()
 *
 * @param int $bookmark_id ID of link
 * @param string $output OBJECT, ARRAY_N, or ARRAY_A
 * @return object|array
 */
function get_link($bookmark_id, $output = OBJECT, $filter = 'raw')
{
    _deprecated_function(__FUNCTION__, '2.1', 'get_bookmark()');
    return get_bookmark($bookmark_id, $output, $filter);
}