WordPress.org

Make WordPress Core

Changeset 14147


Ignore:
Timestamp:
04/18/10 09:18:20 (8 years ago)
Author:
dd32
Message:

Use correct custom post_type token in get_sample_permalink()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/post.php

    r14130 r14147  
    10311031    $permalink = get_permalink($post, true); 
    10321032 
    1033     if ( $ptype->query_var ) // Replace custom post_type Token with generic pagename token for ease of use. 
    1034         $permalink = str_replace('%' . $ptype->query_var . '%', '%pagename%', $permalink); 
     1033    // Replace custom post_type Token with generic pagename token for ease of use. 
     1034    $permalink = str_replace("%$post->post_type%", '%pagename%', $permalink); 
    10351035 
    10361036    // Handle page hierarchy 
Note: See TracChangeset for help on using the changeset viewer.