WordPress.org

Make WordPress Core

Changeset 11928


Ignore:
Timestamp:
09/14/09 02:06:33 (5 years ago)
Author:
azaozz
Message:

Explain that the permalink is temporary for autosave generated permalinks, fixes #7733

Location:
trunk
Files:
2 edited

Legend:

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

    r11925 r11928  
    921921 * @return unknown 
    922922 */ 
    923 function get_sample_permalink($id, $title=null, $name = null) { 
     923function get_sample_permalink($id, $title = null, $name = null) { 
    924924    $post = &get_post($id); 
    925925    if (!$post->ID) { 
     
    982982    $post = &get_post($id); 
    983983    list($permalink, $post_name) = get_sample_permalink($post->ID, $new_title, $new_slug); 
    984     if ( 'publish' == $post->post_status ) 
     984 
     985    if ( 'publish' == $post->post_status ) { 
    985986        $view_post = 'post' == $post->post_type ? __('View Post') : __('View Page'); 
     987        $title = __('Click to edit this part of the permalink'); 
     988    } else { 
     989        $title = __('Temporary permalink. Click to edit this part.'); 
     990    } 
    986991 
    987992    if ( false === strpos($permalink, '%postname%') && false === strpos($permalink, '%pagename%') ) { 
     
    9971002    } 
    9981003 
    999     $title = __('Click to edit this part of the permalink'); 
    1000     if (function_exists('mb_strlen')) { 
    1001         if (mb_strlen($post_name) > 30) { 
     1004    if ( function_exists('mb_strlen') ) { 
     1005        if ( mb_strlen($post_name) > 30 ) { 
    10021006            $post_name_abridged = mb_substr($post_name, 0, 14). '…' . mb_substr($post_name, -14); 
    10031007        } else { 
     
    10051009        } 
    10061010    } else { 
    1007         if (strlen($post_name) > 30) { 
     1011        if ( strlen($post_name) > 30 ) { 
    10081012            $post_name_abridged = substr($post_name, 0, 14). '…' . substr($post_name, -14); 
    10091013        } else { 
  • trunk/wp-includes/script-loader.php

    r11927 r11928  
    276276        $scripts->localize( 'slug', 'slugL10n', array( 
    277277            'requestFile' => admin_url('admin-ajax.php'), 
    278             'save' => __('Save'), 
     278            'save' => __('OK'), 
    279279            'cancel' => __('Cancel'), 
    280280            'l10n_print_after' => 'try{convertEntities(slugL10n);}catch(e){};' 
Note: See TracChangeset for help on using the changeset viewer.