WordPress.org

Codex

Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Function Reference/get blog permalink

Description

Get the permalink for a blog post from any site on the network. This function is the same as get_permalink(), except that you can get the permalink for a post from any blog on the network, not just the current blog.

Usage

 <?php echo get_blog_permalink$blog_id$post_id ); ?> 

Parameters

$blog_id
(integer) (required) ID of the blog.
Default: None
$post_id
(integer) (required) ID of the post you are looking for.
Default: None

Returns

(string) 
The permalink URL.

Example

From any blog in the network, get the permalink for post with ID 6 on blog ID 3.

<?php echo get_blog_permalink( 3, 6 ); ?>

Notes

Change Log

Source File

get_blog_permalink() is located in wp-includes/ms-functions.php.

Related

get_permalink()

See also index of Function Reference and index of Template Tags.
This article is marked as in need of editing. You can help Codex by editing it.