WordPress.org

Make WordPress Core

Ticket #19920: edit-form-advanced.php.patch

File edit-form-advanced.php.patch, 1.2 KB (added by phill_brown, 2 years ago)
  • edit-form-advanced.php

     
    292292</div> 
    293293<div class="inside"> 
    294294<?php 
    295 $sample_permalink_html = $post_type_object->public ? get_sample_permalink_html($post->ID) : ''; 
     295$sample_permalink_html = $post_type_object->publicly_queryable ? get_sample_permalink_html($post->ID) : ''; 
    296296$shortlink = wp_get_shortlink($post->ID, 'post'); 
    297297if ( !empty($shortlink) ) 
    298298    $sample_permalink_html .= '<input id="shortlink" type="hidden" value="' . esc_attr($shortlink) . '" /><a href="#" class="button" onclick="prompt(&#39;URL:&#39;, jQuery(\'#shortlink\').val()); return false;">' . __('Get Shortlink') . '</a>'; 
    299299 
    300 if ( $post_type_object->public && ! ( 'pending' == $post->post_status && !current_user_can( $post_type_object->cap->publish_posts ) ) ) { ?> 
     300if ( $post_type_object->publicly_queryable && ! ( 'pending' == $post->post_status && !current_user_can( $post_type_object->cap->publish_posts ) ) ) { ?> 
    301301        <div id="edit-slug-box"> 
    302302        <?php 
    303303                if ( ! empty($post->ID) && ! empty($sample_permalink_html) && 'auto-draft' != $post->post_status )