Handle page hierarchy when showing the sample permalink. props duck_, fixes #12327.

git-svn-id: https://develop.svn.wordpress.org/trunk@14399 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin
2010-05-03 20:10:26 +00:00
parent a7b2ec8515
commit 2fa9643cf2
2 changed files with 5 additions and 4 deletions
+1 -1
View File
@@ -1036,7 +1036,7 @@ function get_sample_permalink($id, $title = null, $name = null) {
// Handle page hierarchy
if ( $ptype->hierarchical ) {
$uri = get_page_uri($post->ID);
$uri = get_page_uri($post);
$uri = untrailingslashit($uri);
$uri = strrev( stristr( strrev( $uri ), '/' ) );
$uri = untrailingslashit($uri);