Make WordPress Core

Ticket #34521: 34521.2.patch

File 34521.2.patch, 69.2 KB (added by ramiy, 8 years ago)
  • wp-admin/custom-header.php

     
    932932         */
    933933        public function admin_page() {
    934934                if ( ! current_user_can('edit_theme_options') )
    935                         wp_die(__('You do not have permission to customize headers.'));
     935                        wp_die( __( 'You aren’t allowed to customize headers.' ) );
    936936                $step = $this->step();
    937937                if ( 2 == $step )
    938938                        $this->step_2();
  • wp-admin/export.php

     
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    1212if ( !current_user_can('export') )
    13         wp_die(__('You do not have sufficient permissions to export the content of this site.'));
     13        wp_die( __( 'You aren’t allowed to export the content of this site.' ) );
    1414
    1515/** Load WordPress export API */
    1616require_once( ABSPATH . 'wp-admin/includes/export.php' );
  • wp-admin/import.php

     
    1212require_once( dirname( __FILE__ ) . '/admin.php' );
    1313
    1414if ( !current_user_can('import') )
    15         wp_die(__('You do not have sufficient permissions to import content in this site.'));
     15        wp_die( __( 'You aren’t allowed to import content in this site.' ) );
    1616
    1717$title = __('Import');
    1818
  • wp-admin/includes/ajax-actions.php

     
    15951595
    15961596        if ( 'page' == $_POST['post_type'] ) {
    15971597                if ( ! current_user_can( 'edit_page', $post_ID ) )
    1598                         wp_die( __( 'You are not allowed to edit this page.' ) );
     1598                        wp_die( __( 'You aren’t allowed to edit this page.' ) );
    15991599        } else {
    16001600                if ( ! current_user_can( 'edit_post', $post_ID ) )
    1601                         wp_die( __( 'You are not allowed to edit this post.' ) );
     1601                        wp_die( __( 'You aren’t allowed to edit this post.' ) );
    16021602        }
    16031603
    16041604        if ( $last = wp_check_post_lock( $post_ID ) ) {
     
    19891989                echo wp_json_encode( array(
    19901990                        'success' => false,
    19911991                        'data'    => array(
    1992                                 'message'  => __( 'You do not have permission to upload files.' ),
     1992                                'message'  => __( 'You aren’t allowed to upload files.' ),
    19931993                                'filename' => $_FILES['async-upload']['name'],
    19941994                        )
    19951995                ) );
     
    20032003                        echo wp_json_encode( array(
    20042004                                'success' => false,
    20052005                                'data'    => array(
    2006                                         'message'  => __( "You don't have permission to attach files to this post." ),
     2006                                        'message'  => __( 'You aren’t allowed to attach files to this post.' ),
    20072007                                        'filename' => $_FILES['async-upload']['name'],
    20082008                                )
    20092009                        ) );
     
    30723072        }
    30733073
    30743074        if ( ! current_user_can( 'update_plugins' ) ) {
    3075                 $status['error'] = __( 'You do not have sufficient permissions to update plugins for this site.' );
     3075                $status['error'] = __( 'You aren’t allowed to update plugins for this site.' );
    30763076                wp_send_json_error( $status );
    30773077        }
    30783078
  • wp-admin/includes/bookmark.php

     
    2929        if ( ! current_user_can( 'manage_links' ) ) {
    3030                wp_die(
    3131                        '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    32                         '<p>' . __( 'You do not have sufficient permissions to edit the links for this site.' ) . '</p>',
     32                        '<p>' . __( 'You aren&#8217;t allowed to edit the links for this site.' ) . '</p>',
    3333                        403
    3434                );
    3535        }
     
    312312                wp_die( sprintf( __( 'If you are looking to use the link manager, please install the <a href="%s">Link Manager</a> plugin.' ), $link ) );
    313313        }
    314314
    315         wp_die( __( 'You do not have sufficient permissions to edit the links for this site.' ) );
     315        wp_die( __( 'You aren&#8217;t allowed to edit the links for this site.' ) );
    316316}
  • wp-admin/includes/menu.php

     
    339339         */
    340340        do_action( 'admin_page_access_denied' );
    341341
    342         wp_die( __( 'You do not have sufficient permissions to access this page.' ), 403 );
     342        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    343343}
    344344
    345345$menu = add_menu_classes($menu);
  • wp-admin/link-add.php

     
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    1212if ( ! current_user_can('manage_links') )
    13         wp_die(__('You do not have sufficient permissions to add links to this site.'));
     13        wp_die( __( 'You aren&#8217;t allowed to add links to this site.' ) );
    1414
    1515$title = __('Add New Link');
    1616$parent_file = 'link-manager.php';
  • wp-admin/link-manager.php

     
    88
    99/** Load WordPress Administration Bootstrap */
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
     11
    1112if ( ! current_user_can( 'manage_links' ) )
    12         wp_die( __( 'You do not have sufficient permissions to edit the links for this site.' ) );
     13        wp_die( __( 'You aren&#8217;t allowed to edit the links for this site.' ) );
    1314
    1415$wp_list_table = _get_list_table('WP_Links_List_Table');
    1516
  • wp-admin/ms-delete-site.php

     
    1313        wp_die( __( 'Multisite support is not enabled.' ) );
    1414
    1515if ( ! current_user_can( 'delete_site' ) )
    16         wp_die(__( 'You do not have sufficient permissions to delete this site.'));
     16        wp_die( __( 'You aren&#8217;t allowed to delete this site.' ) );
    1717
    1818if ( isset( $_GET['h'] ) && $_GET['h'] != '' && get_option( 'delete_blog_hash' ) != false ) {
    1919        if ( get_option( 'delete_blog_hash' ) == $_GET['h'] ) {
  • wp-admin/my-sites.php

     
    1313        wp_die( __( 'Multisite support is not enabled.' ) );
    1414
    1515if ( ! current_user_can('read') )
    16         wp_die( __( 'You do not have sufficient permissions to access this page.' ) );
     16        wp_die( __( 'You aren&#8217;t allowed to access this page.' ) );
    1717
    1818$action = isset( $_POST['action'] ) ? $_POST['action'] : 'splash';
    1919
  • wp-admin/network/index.php

     
    1717        wp_die( __( 'Multisite support is not enabled.' ) );
    1818
    1919if ( ! current_user_can( 'manage_network' ) )
    20         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     20        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    2121
    2222$title = __( 'Dashboard' );
    2323$parent_file = 'index.php';
  • wp-admin/network/settings.php

     
    1717        wp_die( __( 'Multisite support is not enabled.' ) );
    1818
    1919if ( ! current_user_can( 'manage_network_options' ) )
    20         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     20        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    2121
    2222$title = __( 'Network Settings' );
    2323$parent_file = 'settings.php';
  • wp-admin/network/site-info.php

     
    1515}
    1616
    1717if ( ! current_user_can( 'manage_sites' ) ) {
    18         wp_die( __( 'You do not have sufficient permissions to edit this site.' ) );
     18        wp_die( __( 'You aren&#8217;t allowed to edit this site.' ), 403 );
    1919}
    2020
    2121get_current_screen()->add_help_tab( array(
     
    4747}
    4848
    4949if ( ! can_edit_network( $details->site_id ) ) {
    50         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     50        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    5151}
    5252
    5353$parsed_scheme = parse_url( $details->siteurl, PHP_URL_SCHEME );
  • wp-admin/network/site-new.php

     
    1717        wp_die( __( 'Multisite support is not enabled.' ) );
    1818
    1919if ( ! current_user_can( 'manage_sites' ) )
    20         wp_die( __( 'You do not have sufficient permissions to add sites to this network.' ) );
     20        wp_die( __( 'You aren&#8217;t allowed to add sites to this network.' ), 403 );
    2121
    2222get_current_screen()->add_help_tab( array(
    2323        'id'      => 'overview',
  • wp-admin/network/site-settings.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( ! current_user_can( 'manage_sites' ) )
    17         wp_die( __( 'You do not have sufficient permissions to edit this site.' ) );
     17        wp_die( __( 'You aren&#8217;t allowed to edit this site.' ), 403 );
    1818
    1919get_current_screen()->add_help_tab( array(
    2020        'id'      => 'overview',
     
    4444}
    4545
    4646if ( !can_edit_network( $details->site_id ) )
    47         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     47        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    4848
    4949$is_main_site = is_main_site( $id );
    5050
  • wp-admin/network/site-themes.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( ! current_user_can( 'manage_sites' ) )
    17         wp_die( __( 'You do not have sufficient permissions to manage themes for this site.' ) );
     17        wp_die( __( 'You aren&#8217;t allowed to manage themes for this site.' ), 403 );
    1818
    1919get_current_screen()->add_help_tab( array(
    2020        'id'      => 'overview',
     
    6767}
    6868
    6969if ( !can_edit_network( $details->site_id ) )
    70         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     70        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    7171
    7272$is_main_site = is_main_site( $id );
    7373
  • wp-admin/network/site-users.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( ! current_user_can('manage_sites') )
    17         wp_die(__('You do not have sufficient permissions to edit this site.'));
     17        wp_die( __( 'You aren&#8217;t allowed to edit this site.' ), 403 );
    1818
    1919$wp_list_table = _get_list_table('WP_Users_List_Table');
    2020$wp_list_table->prepare_items();
     
    6060}
    6161
    6262if ( ! can_edit_network( $details->site_id ) )
    63         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     63        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    6464
    6565$is_main_site = is_main_site( $id );
    6666
  • wp-admin/network/sites.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( ! current_user_can( 'manage_sites' ) )
    17         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     17        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    1818
    1919$wp_list_table = _get_list_table( 'WP_MS_Sites_List_Table' );
    2020$pagenum = $wp_list_table->get_pagenum();
     
    9191                }
    9292
    9393                if ( $current_site->blog_id == $id ) {
    94                         wp_die( __( 'You are not allowed to change the current site.' ) );
     94                        wp_die( __( 'You aren&#8217;t allowed to change the current site.' ), 403 );
    9595                }
    9696
    9797                $site_details = get_blog_details( $id );
     
    126126
    127127                case 'deleteblog':
    128128                        if ( ! current_user_can( 'delete_sites' ) )
    129                                 wp_die( __( 'You do not have permission to access this page.' ), '', array( 'response' => 403 ) );
     129                                wp_die( __( 'You aren&#8217;t allowed to access this page.' ), '', array( 'response' => 403 ) );
    130130
    131131                        $updated_action = 'not_deleted';
    132132                        if ( $id != '0' && $id != $current_site->blog_id && current_user_can( 'delete_site', $id ) ) {
     
    144144                                                switch ( $doaction ) {
    145145                                                        case 'delete':
    146146                                                                if ( ! current_user_can( 'delete_site', $val ) )
    147                                                                         wp_die( __( 'You are not allowed to delete the site.' ) );
     147                                                                        wp_die( __( 'You aren&#8217;t allowed to delete the site.' ), 403 );
    148148
    149149                                                                $updated_action = 'all_delete';
    150150                                                                wpmu_delete_blog( $val, true );
     
    157157                                                        break;
    158158                                                }
    159159                                        } else {
    160                                                 wp_die( __( 'You are not allowed to change the current site.' ) );
     160                                                wp_die( __( 'You aren&#8217;t allowed to change the current site.' ), 403 );
    161161                                        }
    162162                                }
    163163                        } else {
     
    233233                        $msg = __( 'Site deleted.' );
    234234                break;
    235235                case 'not_deleted':
    236                         $msg = __( 'You do not have permission to delete that site.' );
     236                        $msg = __( 'You aren&#8217;t allowed to delete that site.' );
    237237                break;
    238238                case 'archiveblog':
    239239                        $msg = __( 'Site archived.' );
  • wp-admin/network/themes.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( !current_user_can('manage_network_themes') )
    17         wp_die( __( 'You do not have sufficient permissions to manage network themes.' ) );
     17        wp_die( __( 'You aren&#8217;t allowed to manage network themes.' ), 403 );
    1818
    1919$wp_list_table = _get_list_table('WP_MS_Themes_List_Table');
    2020$pagenum = $wp_list_table->get_pagenum();
     
    9797                        exit;
    9898                case 'delete-selected':
    9999                        if ( ! current_user_can( 'delete_themes' ) ) {
    100                                 wp_die( __('You do not have sufficient permissions to delete themes for this site.') );
     100                                wp_die( __( 'You aren&#8217;t allowed to delete themes for this site.' ), 403 );
    101101                        }
    102102
    103103                        check_admin_referer( 'bulk-themes' );
  • wp-admin/network/user-new.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( ! current_user_can('create_users') )
    17         wp_die(__('You do not have sufficient permissions to add users to this network.'));
     17        wp_die( __( 'You aren&#8217;t allowed to add users to this network.' ), 403 );
    1818
    1919get_current_screen()->add_help_tab( array(
    2020        'id'      => 'overview',
     
    3434        check_admin_referer( 'add-user', '_wpnonce_add-user' );
    3535
    3636        if ( ! current_user_can( 'manage_network_users' ) )
    37                 wp_die( __( 'You do not have permission to access this page.' ), 403 );
     37                wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    3838
    3939        if ( ! is_array( $_POST['user'] ) )
    4040                wp_die( __( 'Cannot create an empty user.' ) );
  • wp-admin/network/users.php

     
    1414        wp_die( __( 'Multisite support is not enabled.' ) );
    1515
    1616if ( ! current_user_can( 'manage_network_users' ) )
    17         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     17        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    1818
    1919if ( isset( $_GET['action'] ) ) {
    2020        /** This action is documented in wp-admin/network/edit.php */
     
    2323        switch ( $_GET['action'] ) {
    2424                case 'deleteuser':
    2525                        if ( ! current_user_can( 'manage_network_users' ) )
    26                                 wp_die( __( 'You do not have permission to access this page.' ), 403 );
     26                                wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    2727
    2828                        check_admin_referer( 'deleteuser' );
    2929
     
    4444
    4545                case 'allusers':
    4646                        if ( !current_user_can( 'manage_network_users' ) )
    47                                 wp_die( __( 'You do not have permission to access this page.' ), 403 );
     47                                wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    4848
    4949                        if ( ( isset( $_POST['action']) || isset($_POST['action2'] ) ) && isset( $_POST['allusers'] ) ) {
    5050                                check_admin_referer( 'bulk-users-network' );
     
    5757                                                switch ( $doaction ) {
    5858                                                        case 'delete':
    5959                                                                if ( ! current_user_can( 'delete_users' ) )
    60                                                                         wp_die( __( 'You do not have permission to access this page.' ), 403 );
     60                                                                        wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    6161                                                                $title = __( 'Users' );
    6262                                                                $parent_file = 'users.php';
    6363                                                                require_once( ABSPATH . 'wp-admin/admin-header.php' );
     
    106106                case 'dodelete':
    107107                        check_admin_referer( 'ms-users-delete' );
    108108                        if ( ! ( current_user_can( 'manage_network_users' ) && current_user_can( 'delete_users' ) ) )
    109                                 wp_die( __( 'You do not have permission to access this page.' ), 403 );
     109                                wp_die( __( 'You aren&#8217;t allowed to access this page.' ), 403 );
    110110
    111111                        if ( ! empty( $_POST['blog'] ) && is_array( $_POST['blog'] ) ) {
    112112                                foreach ( $_POST['blog'] as $id => $users ) {
  • wp-admin/options-discussion.php

     
    99require_once( dirname( __FILE__ ) . '/admin.php' );
    1010
    1111if ( ! current_user_can( 'manage_options' ) )
    12         wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
     12        wp_die( __( 'You aren&#8217;t allowed to manage options for this site.' ) );
    1313
    1414$title = __('Discussion Settings');
    1515$parent_file = 'options-general.php';
  • wp-admin/options-general.php

     
    1313require_once( ABSPATH . 'wp-admin/includes/translation-install.php' );
    1414
    1515if ( ! current_user_can( 'manage_options' ) )
    16         wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
     16        wp_die( __( 'You aren&#8217;t allowed to manage options for this site.' ) );
    1717
    1818$title = __('General Settings');
    1919$parent_file = 'options-general.php';
  • wp-admin/options-media.php

     
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    1212if ( ! current_user_can( 'manage_options' ) )
    13         wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
     13        wp_die( __( 'You aren&#8217;t allowed to manage options for this site.' ) );
    1414
    1515$title = __('Media Settings');
    1616$parent_file = 'options-general.php';
  • wp-admin/options-permalink.php

     
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    1212if ( ! current_user_can( 'manage_options' ) )
    13         wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
     13        wp_die( __( 'You aren&#8217;t allowed to manage options for this site.' ) );
    1414
    1515$title = __('Permalink Settings');
    1616$parent_file = 'options-general.php';
  • wp-admin/options-reading.php

     
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    1212if ( ! current_user_can( 'manage_options' ) )
    13         wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
     13        wp_die( __( 'You aren&#8217;t allowed to manage options for this site.' ) );
    1414
    1515$title = __( 'Reading Settings' );
    1616$parent_file = 'options-general.php';
  • wp-admin/options-writing.php

     
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    1212if ( ! current_user_can( 'manage_options' ) )
    13         wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
     13        wp_die( __( 'You aren&#8217;t allowed to manage options for this site.' ) );
    1414
    1515$title = __('Writing Settings');
    1616$parent_file = 'options-general.php';
  • wp-admin/options.php

     
    4747if ( ! current_user_can( $capability ) ) {
    4848        wp_die(
    4949                '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    50                 '<p>' . __( 'You are not allowed to manage these items.' ) . '</p>',
     50                '<p>' . __( 'You aren&#8217;t allowed to manage these items.' ) . '</p>',
    5151                403
    5252        );
    5353}
     
    7676if ( is_multisite() && ! is_super_admin() && 'update' != $action ) {
    7777        wp_die(
    7878                '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    79                 '<p>' . __( 'You are not allowed to delete these items.' ) . '</p>',
     79                '<p>' . __( 'You aren&#8217;t allowed to delete these items.' ) . '</p>',
    8080                403
    8181        );
    8282}
     
    169169
    170170        if ( 'options' == $option_page ) {
    171171                if ( is_multisite() && ! is_super_admin() )
    172                         wp_die( __( 'You do not have sufficient permissions to modify unregistered settings for this site.' ) );
     172                        wp_die( __( 'You aren&#8217;t allowed to modify unregistered settings for this site.' ) );
    173173                $options = explode( ',', wp_unslash( $_POST[ 'page_options' ] ) );
    174174        } else {
    175175                $options = $whitelist_options[ $option_page ];
  • wp-admin/plugin-editor.php

     
    1414        exit();
    1515}
    1616
    17 if ( !current_user_can('edit_plugins') )
    18         wp_die( __('You do not have sufficient permissions to edit plugins for this site.') );
     17if ( !current_user_can( 'edit_plugins' ) )
     18        wp_die( __( 'You aren&#8217;t allowed to edit plugins for this site.' ) );
    1919
    20 $title = __("Edit Plugins");
     20$title = __('Edit Plugins');
    2121$parent_file = 'plugins.php';
    2222
    2323wp_reset_vars( array( 'action', 'error', 'file', 'plugin' ) );
  • wp-admin/plugin-install.php

     
    1414 */
    1515require_once( dirname( __FILE__ ) . '/admin.php' );
    1616
    17 if ( ! current_user_can('install_plugins') )
    18         wp_die(__('You do not have sufficient permissions to install plugins on this site.'));
     17if ( ! current_user_can( 'install_plugins' ) )
     18        wp_die( __( 'You aren&#8217;t allowed to install plugins on this site.' ) );
    1919
    2020if ( is_multisite() && ! is_network_admin() ) {
    2121        wp_redirect( network_admin_url( 'plugin-install.php' ) );
  • wp-admin/plugins.php

     
    99/** WordPress Administration Bootstrap */
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    12 if ( ! current_user_can('activate_plugins') )
    13         wp_die( __( 'You do not have sufficient permissions to manage plugins for this site.' ) );
     12if ( ! current_user_can( 'activate_plugins' ) )
     13        wp_die( __( 'You aren&#8217;t allowed to manage plugins for this site.' ) );
    1414
    1515$wp_list_table = _get_list_table('WP_Plugins_List_Table');
    1616$pagenum = $wp_list_table->get_pagenum();
     
    3030        switch ( $action ) {
    3131                case 'activate':
    3232                        if ( ! current_user_can('activate_plugins') )
    33                                 wp_die(__('You do not have sufficient permissions to activate plugins for this site.'));
     33                                wp_die( __( 'You aren&#8217;t allowed to activate plugins for this site.' ) );
    3434
    3535                        if ( is_multisite() && ! is_network_admin() && is_network_only_plugin( $plugin ) ) {
    3636                                wp_redirect( self_admin_url("plugins.php?plugin_status=$status&paged=$page&s=$s") );
     
    6969
    7070                case 'activate-selected':
    7171                        if ( ! current_user_can('activate_plugins') )
    72                                 wp_die(__('You do not have sufficient permissions to activate plugins for this site.'));
     72                                wp_die( __( 'You aren&#8217;t allowed to activate plugins for this site.' ) );
    7373
    7474                        check_admin_referer('bulk-plugins');
    7575
     
    147147
    148148                case 'error_scrape':
    149149                        if ( ! current_user_can('activate_plugins') )
    150                                 wp_die(__('You do not have sufficient permissions to activate plugins for this site.'));
     150                                wp_die( __( 'You aren&#8217;t allowed to activate plugins for this site.' ) );
    151151
    152152                        check_admin_referer('plugin-activation-error_' . $plugin);
    153153
     
    168168
    169169                case 'deactivate':
    170170                        if ( ! current_user_can('activate_plugins') )
    171                                 wp_die(__('You do not have sufficient permissions to deactivate plugins for this site.'));
     171                                wp_die( __( 'You aren&#8217;t allowed to deactivate plugins for this site.' ) );
    172172
    173173                        check_admin_referer('deactivate-plugin_' . $plugin);
    174174
     
    193193
    194194                case 'deactivate-selected':
    195195                        if ( ! current_user_can('activate_plugins') )
    196                                 wp_die(__('You do not have sufficient permissions to deactivate plugins for this site.'));
     196                                wp_die( __( 'You aren&#8217;t allowed to deactivate plugins for this site.' ) );
    197197
    198198                        check_admin_referer('bulk-plugins');
    199199
     
    228228
    229229                case 'delete-selected':
    230230                        if ( ! current_user_can('delete_plugins') ) {
    231                                 wp_die(__('You do not have sufficient permissions to delete plugins for this site.'));
     231                                wp_die( __( 'You aren&#8217;t allowed to delete plugins for this site.' ) );
    232232                        }
    233233
    234234                        check_admin_referer('bulk-plugins');
  • wp-admin/theme-editor.php

     
    1414        exit();
    1515}
    1616
    17 if ( !current_user_can('edit_themes') )
    18         wp_die('<p>'.__('You do not have sufficient permissions to edit templates for this site.').'</p>');
     17if ( !current_user_can( 'edit_themes' ) )
     18        wp_die( '<p>' . __( 'You aren&#8217;t allowed to edit templates for this site.' ) . '</p>' );
    1919
    20 $title = __("Edit Themes");
     20$title = __( 'Edit Themes' );
    2121$parent_file = 'themes.php';
    2222
    2323get_current_screen()->add_help_tab( array(
  • wp-admin/theme-install.php

     
    1212
    1313wp_reset_vars( array( 'tab' ) );
    1414
    15 if ( ! current_user_can('install_themes') )
    16         wp_die( __( 'You do not have sufficient permissions to install themes on this site.' ) );
     15if ( ! current_user_can( 'install_themes' ) )
     16        wp_die( __( 'You aren&#8217;t allowed to install themes on this site.' ) );
    1717
    1818if ( is_multisite() && ! is_network_admin() ) {
    1919        wp_redirect( network_admin_url( 'theme-install.php' ) );
  • wp-admin/update-core.php

     
    2020}
    2121
    2222if ( ! current_user_can( 'update_core' ) && ! current_user_can( 'update_themes' ) && ! current_user_can( 'update_plugins' ) )
    23         wp_die( __( 'You do not have sufficient permissions to update this site.' ) );
     23        wp_die( __( 'You aren&#8217;t allowed to update this site.' ) );
    2424
    2525/**
    2626 *
     
    599599} elseif ( 'do-core-upgrade' == $action || 'do-core-reinstall' == $action ) {
    600600
    601601        if ( ! current_user_can( 'update_core' ) )
    602                 wp_die( __( 'You do not have sufficient permissions to update this site.' ) );
     602                wp_die( __( 'You aren&#8217;t allowed to update this site.' ) );
    603603
    604604        check_admin_referer('upgrade-core');
    605605
     
    623623} elseif ( 'do-plugin-upgrade' == $action ) {
    624624
    625625        if ( ! current_user_can( 'update_plugins' ) )
    626                 wp_die( __( 'You do not have sufficient permissions to update this site.' ) );
     626                wp_die( __( 'You aren&#8217;t allowed to update this site.' ) );
    627627
    628628        check_admin_referer('upgrade-core');
    629629
     
    651651} elseif ( 'do-theme-upgrade' == $action ) {
    652652
    653653        if ( ! current_user_can( 'update_themes' ) )
    654                 wp_die( __( 'You do not have sufficient permissions to update this site.' ) );
     654                wp_die( __( 'You aren&#8217;t allowed to update this site.' ) );
    655655
    656656        check_admin_referer('upgrade-core');
    657657
     
    681681} elseif ( 'do-translation-upgrade' == $action ) {
    682682
    683683        if ( ! current_user_can( 'update_core' ) && ! current_user_can( 'update_plugins' ) && ! current_user_can( 'update_themes' ) )
    684                 wp_die( __( 'You do not have sufficient permissions to update this site.' ) );
     684                wp_die( __( 'You aren&#8217;t allowed to update this site.' ) );
    685685
    686686        check_admin_referer( 'upgrade-translations' );
    687687
  • wp-admin/update.php

     
    2121
    2222        if ( 'update-selected' == $action ) {
    2323                if ( ! current_user_can( 'update_plugins' ) )
    24                         wp_die( __( 'You do not have sufficient permissions to update plugins for this site.' ) );
     24                        wp_die( __( 'You aren&#8217;t allowed to update plugins for this site.' ) );
    2525
    2626                check_admin_referer( 'bulk-update-plugins' );
    2727
     
    4747
    4848        } elseif ( 'upgrade-plugin' == $action ) {
    4949                if ( ! current_user_can('update_plugins') )
    50                         wp_die(__('You do not have sufficient permissions to update plugins for this site.'));
     50                        wp_die(__('You aren&#8217;t allowed to update plugins for this site.'));
    5151
    5252                check_admin_referer('upgrade-plugin_' . $plugin);
    5353
     
    6868
    6969        } elseif ('activate-plugin' == $action ) {
    7070                if ( ! current_user_can('update_plugins') )
    71                         wp_die(__('You do not have sufficient permissions to update plugins for this site.'));
     71                        wp_die(__('You aren&#8217;t allowed to update plugins for this site.'));
    7272
    7373                check_admin_referer('activate-plugin_' . $plugin);
    7474                if ( ! isset($_GET['failure']) && ! isset($_GET['success']) ) {
     
    9393        } elseif ( 'install-plugin' == $action ) {
    9494
    9595                if ( ! current_user_can('install_plugins') )
    96                         wp_die( __( 'You do not have sufficient permissions to install plugins on this site.' ) );
     96                        wp_die( __( 'You aren&#8217;t allowed to install plugins on this site.' ) );
    9797
    9898                include_once( ABSPATH . 'wp-admin/includes/plugin-install.php' ); //for plugins_api..
    9999
     
    141141        } elseif ( 'upload-plugin' == $action ) {
    142142
    143143                if ( ! current_user_can( 'upload_plugins' ) ) {
    144                         wp_die( __( 'You do not have sufficient permissions to install plugins on this site.' ) );
     144                        wp_die( __( 'You aren&#8217;t allowed to install plugins on this site.' ) );
    145145                }
    146146
    147147                check_admin_referer('plugin-upload');
     
    169169        } elseif ( 'upgrade-theme' == $action ) {
    170170
    171171                if ( ! current_user_can('update_themes') )
    172                         wp_die(__('You do not have sufficient permissions to update themes for this site.'));
     172                        wp_die(__('You aren&#8217;t allowed to update themes for this site.'));
    173173
    174174                check_admin_referer('upgrade-theme_' . $theme);
    175175
     
    190190                include(ABSPATH . 'wp-admin/admin-footer.php');
    191191        } elseif ( 'update-selected-themes' == $action ) {
    192192                if ( ! current_user_can( 'update_themes' ) )
    193                         wp_die( __( 'You do not have sufficient permissions to update themes for this site.' ) );
     193                        wp_die( __( 'You aren&#8217;t allowed to update themes for this site.' ) );
    194194
    195195                check_admin_referer( 'bulk-update-themes' );
    196196
     
    216216        } elseif ( 'install-theme' == $action ) {
    217217
    218218                if ( ! current_user_can('install_themes') )
    219                         wp_die( __( 'You do not have sufficient permissions to install themes on this site.' ) );
     219                        wp_die( __( 'You aren&#8217;t allowed to install themes on this site.' ) );
    220220
    221221                include_once( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); //for themes_api..
    222222
     
    246246        } elseif ( 'upload-theme' == $action ) {
    247247
    248248                if ( ! current_user_can( 'upload_themes' ) ) {
    249                         wp_die( __( 'You do not have sufficient permissions to install themes on this site.' ) );
     249                        wp_die( __( 'You aren&#8217;t allowed to install themes on this site.' ) );
    250250                }
    251251
    252252                check_admin_referer('theme-upload');
  • wp-admin/user-edit.php

     
    7777        && $user_id != $current_user->ID
    7878        && ! apply_filters( 'enable_edit_any_user_configuration', true )
    7979) {
    80         wp_die( __( 'You do not have permission to edit this user.' ) );
     80        wp_die( __( 'You aren&#8217;t allowed to edit this user.' ) );
    8181}
    8282
    8383// Execute confirmed email change. See send_confirmation_on_profile_email().
     
    106106check_admin_referer('update-user_' . $user_id);
    107107
    108108if ( !current_user_can('edit_user', $user_id) )
    109         wp_die(__('You do not have permission to edit this user.'));
     109        wp_die( __( 'You aren&#8217;t allowed to edit this user.' ) );
    110110
    111111if ( IS_PROFILE_PAGE ) {
    112112        /**
     
    159159$profileuser = get_user_to_edit($user_id);
    160160
    161161if ( !current_user_can('edit_user', $user_id) )
    162         wp_die(__('You do not have permission to edit this user.'));
     162        wp_die( __( 'You aren&#8217;t allowed to edit this user.' ) );
    163163
    164164$sessions = WP_Session_Tokens::get_instance( $profileuser->ID );
    165165
  • wp-admin/user-new.php

     
    1313        if ( ! current_user_can( 'create_users' ) && ! current_user_can( 'promote_users' ) ) {
    1414                wp_die(
    1515                        '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    16                         '<p>' . __( 'You do not have sufficient permissions to add users to this network.' ) . '</p>',
     16                        '<p>' . __( 'You aren&#8217;t allowed to add users to this network.' ) . '</p>',
    1717                        403
    1818                );
    1919        }
     
    2020} elseif ( ! current_user_can( 'create_users' ) ) {
    2121        wp_die(
    2222                '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    23                 '<p>' . __( 'You are not allowed to create users.' ) . '</p>',
     23                '<p>' . __( 'You aren&#8217;t allowed to create users.' ) . '</p>',
    2424                403
    2525        );
    2626}
     
    5353        if ( ! current_user_can( 'promote_user', $user_details->ID ) ) {
    5454                wp_die(
    5555                        '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    56                         '<p>' . __( 'You do not have sufficient permissions to add users to this network.' ) . '</p>',
     56                        '<p>' . __( 'You aren&#8217;t allowed to add users to this network.' ) . '</p>',
    5757                        403
    5858                );
    5959        }
     
    107107        if ( ! current_user_can( 'create_users' ) ) {
    108108                wp_die(
    109109                        '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    110                         '<p>' . __( 'You are not allowed to create users.' ) . '</p>',
     110                        '<p>' . __( 'You aren&#8217;t allowed to create users.' ) . '</p>',
    111111                        403
    112112                );
    113113        }
  • wp-includes/class-wp-xmlrpc-server.php

     
    12331233                if ( 'private' === $post_data['post_status'] || ! empty( $post_data['post_password'] ) ) {
    12341234                        // Error if the client tried to stick the post, otherwise, silently unstick.
    12351235                        if ( ! empty( $post_data['sticky'] ) ) {
    1236                                 return new IXR_Error( 401, __( 'Sorry, you cannot stick a private post.' ) );
     1236                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to make this post private.' ) );
    12371237                        }
    12381238
    12391239                        if ( $update ) {
     
    12411241                        }
    12421242                } elseif ( isset( $post_data['sticky'] ) )  {
    12431243                        if ( ! current_user_can( $post_type->cap->edit_others_posts ) ) {
    1244                                 return new IXR_Error( 401, __( 'Sorry, you are not allowed to stick this post.' ) );
     1244                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to make this post sticky.' ) );
    12451245                        }
    12461246
    12471247                        $sticky = wp_validate_boolean( $post_data['sticky'] );
     
    12811281                        if ( ! get_post( $post_data['ID'] ) )
    12821282                                return new IXR_Error( 401, __( 'Invalid post ID.' ) );
    12831283                        if ( ! current_user_can( 'edit_post', $post_data['ID'] ) )
    1284                                 return new IXR_Error( 401, __( 'Sorry, you are not allowed to edit this post.' ) );
     1284                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    12851285                        if ( $post_data['post_type'] != get_post_type( $post_data['ID'] ) )
    12861286                                return new IXR_Error( 401, __( 'The post type may not be changed.' ) );
    12871287                } else {
    12881288                        if ( ! current_user_can( $post_type->cap->create_posts ) || ! current_user_can( $post_type->cap->edit_posts ) )
    1289                                 return new IXR_Error( 401, __( 'Sorry, you are not allowed to post on this site.' ) );
     1289                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to post on this site.' ) );
    12901290                }
    12911291
    12921292                switch ( $post_data['post_status'] ) {
     
    12951295                                break;
    12961296                        case 'private':
    12971297                                if ( ! current_user_can( $post_type->cap->publish_posts ) )
    1298                                         return new IXR_Error( 401, __( 'Sorry, you are not allowed to create private posts in this post type' ) );
     1298                                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to create private posts in this post type.' ) );
    12991299                                break;
    13001300                        case 'publish':
    13011301                        case 'future':
    13021302                                if ( ! current_user_can( $post_type->cap->publish_posts ) )
    1303                                         return new IXR_Error( 401, __( 'Sorry, you are not allowed to publish posts in this post type' ) );
     1303                                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to publish posts in this post type.' ) );
    13041304                                break;
    13051305                        default:
    13061306                                if ( ! get_post_status_object( $post_data['post_status'] ) )
     
    13091309                }
    13101310
    13111311                if ( ! empty( $post_data['post_password'] ) && ! current_user_can( $post_type->cap->publish_posts ) )
    1312                         return new IXR_Error( 401, __( 'Sorry, you are not allowed to create password protected posts in this post type' ) );
     1312                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to create password protected posts in this post type.' ) );
    13131313
    13141314                $post_data['post_author'] = absint( $post_data['post_author'] );
    13151315                if ( ! empty( $post_data['post_author'] ) && $post_data['post_author'] != $user->ID ) {
    13161316                        if ( ! current_user_can( $post_type->cap->edit_others_posts ) )
    1317                                 return new IXR_Error( 401, __( 'You are not allowed to create posts as this user.' ) );
     1317                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to create posts as this user.' ) );
    13181318
    13191319                        $author = get_userdata( $post_data['post_author'] );
    13201320
     
    13801380                                // Validating term ids.
    13811381                                foreach ( $taxonomies as $taxonomy ) {
    13821382                                        if ( ! array_key_exists( $taxonomy , $post_type_taxonomies ) )
    1383                                                 return new IXR_Error( 401, __( 'Sorry, one of the given taxonomies is not supported by the post type.' ) );
     1383                                                return new IXR_Error( 401, __( 'One of the given taxonomies is not supported by the post type.' ) );
    13841384
    13851385                                        if ( ! current_user_can( $post_type_taxonomies[$taxonomy]->cap->assign_terms ) )
    1386                                                 return new IXR_Error( 401, __( 'Sorry, you are not allowed to assign a term to one of the given taxonomies.' ) );
     1386                                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to assign a term to one of the given taxonomies.' ) );
    13871387
    13881388                                        $term_ids = $post_data['terms'][$taxonomy];
    13891389                                        $terms[ $taxonomy ] = array();
     
    14041404
    14051405                                foreach ( $taxonomies as $taxonomy ) {
    14061406                                        if ( ! array_key_exists( $taxonomy , $post_type_taxonomies ) )
    1407                                                 return new IXR_Error( 401, __( 'Sorry, one of the given taxonomies is not supported by the post type.' ) );
     1407                                                return new IXR_Error( 401, __( 'One of the given taxonomies is not supported by the post type.' ) );
    14081408
    14091409                                        if ( ! current_user_can( $post_type_taxonomies[$taxonomy]->cap->assign_terms ) )
    1410                                                 return new IXR_Error( 401, __( 'Sorry, you are not allowed to assign a term to one of the given taxonomies.' ) );
     1410                                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to assign a term to one of the given taxonomies.' ) );
    14111411
    14121412                                        /*
    14131413                                         * For hierarchical taxonomies, we can't assign a term when multiple terms
     
    14361436                                                if ( ! $term ) {
    14371437                                                        // Term doesn't exist, so check that the user is allowed to create new terms.
    14381438                                                        if ( ! current_user_can( $post_type_taxonomies[$taxonomy]->cap->edit_terms ) )
    1439                                                                 return new IXR_Error( 401, __( 'Sorry, you are not allowed to add a term to one of the given taxonomies.' ) );
     1439                                                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to add a term to one of the given taxonomies.' ) );
    14401440
    14411441                                                        // Create the new term.
    14421442                                                        $term_info = wp_insert_term( $term_name, $taxonomy );
     
    14881488                        return new IXR_Error( 500, $post_ID->get_error_message() );
    14891489
    14901490                if ( ! $post_ID )
    1491                         return new IXR_Error( 401, __( 'Sorry, your entry could not be posted. Something wrong happened.' ) );
     1491                        return new IXR_Error( 401, __( 'Your entry could not be posted. Something wrong happened.' ) );
    14921492
    14931493                return strval( $post_ID );
    14941494        }
     
    16021602                }
    16031603
    16041604                if ( ! current_user_can( 'delete_post', $post_id ) ) {
    1605                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to delete this post.' ) );
     1605                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to delete this post.' ) );
    16061606                }
    16071607
    16081608                $result = wp_delete_post( $post_id );
     
    16991699                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    17001700
    17011701                if ( ! current_user_can( 'edit_post', $post_id ) )
    1702                         return new IXR_Error( 401, __( 'Sorry, you cannot edit this post.' ) );
     1702                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    17031703
    17041704                return $this->_prepare_post( $post, $fields );
    17051705        }
     
    17601760                }
    17611761
    17621762                if ( ! current_user_can( $post_type->cap->edit_posts ) )
    1763                         return new IXR_Error( 401, __( 'You are not allowed to edit posts in this post type.' ));
     1763                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit posts in this post type.' ));
    17641764
    17651765                $query['post_type'] = $post_type->name;
    17661766
     
    18431843                $taxonomy = get_taxonomy( $content_struct['taxonomy'] );
    18441844
    18451845                if ( ! current_user_can( $taxonomy->cap->manage_terms ) )
    1846                         return new IXR_Error( 401, __( 'You are not allowed to create terms in this taxonomy.' ) );
     1846                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to create terms in this taxonomy.' ) );
    18471847
    18481848                $taxonomy = (array) $taxonomy;
    18491849
     
    18821882                        return new IXR_Error( 500, $term->get_error_message() );
    18831883
    18841884                if ( ! $term )
    1885                         return new IXR_Error( 500, __( 'Sorry, your term could not be created. Something wrong happened.' ) );
     1885                        return new IXR_Error( 500, __( 'The term could not be created. Something wrong happened.' ) );
    18861886
    18871887                return strval( $term['term_id'] );
    18881888        }
     
    19301930                $taxonomy = get_taxonomy( $content_struct['taxonomy'] );
    19311931
    19321932                if ( ! current_user_can( $taxonomy->cap->edit_terms ) )
    1933                         return new IXR_Error( 401, __( 'You are not allowed to edit terms in this taxonomy.' ) );
     1933                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit terms in this taxonomy.' ) );
    19341934
    19351935                $taxonomy = (array) $taxonomy;
    19361936
     
    19801980                        return new IXR_Error( 500, $term->get_error_message() );
    19811981
    19821982                if ( ! $term )
    1983                         return new IXR_Error( 500, __( 'Sorry, editing the term failed.' ) );
     1983                        return new IXR_Error( 500, __( 'Failed editing the term.' ) );
    19841984
    19851985                return true;
    19861986        }
     
    20262026                $taxonomy = get_taxonomy( $taxonomy );
    20272027
    20282028                if ( ! current_user_can( $taxonomy->cap->delete_terms ) )
    2029                         return new IXR_Error( 401, __( 'You are not allowed to delete terms in this taxonomy.' ) );
     2029                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to delete terms in this taxonomy.' ) );
    20302030
    20312031                $term = get_term( $term_id, $taxonomy->name );
    20322032
     
    20422042                        return new IXR_Error( 500, $term->get_error_message() );
    20432043
    20442044                if ( ! $result )
    2045                         return new IXR_Error( 500, __( 'Sorry, deleting the term failed.' ) );
     2045                        return new IXR_Error( 500, __( 'Failed deleting the term.' ) );
    20462046
    20472047                return $result;
    20482048        }
     
    20972097                $taxonomy = get_taxonomy( $taxonomy );
    20982098
    20992099                if ( ! current_user_can( $taxonomy->cap->assign_terms ) )
    2100                         return new IXR_Error( 401, __( 'You are not allowed to assign terms in this taxonomy.' ) );
     2100                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to assign terms in this taxonomy.' ) );
    21012101
    21022102                $term = get_term( $term_id , $taxonomy->name, ARRAY_A );
    21032103
     
    21552155                $taxonomy = get_taxonomy( $taxonomy );
    21562156
    21572157                if ( ! current_user_can( $taxonomy->cap->assign_terms ) )
    2158                         return new IXR_Error( 401, __( 'You are not allowed to assign terms in this taxonomy.' ) );
     2158                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to assign terms in this taxonomy.' ) );
    21592159
    21602160                $query = array();
    21612161
     
    22502250                $taxonomy = get_taxonomy( $taxonomy );
    22512251
    22522252                if ( ! current_user_can( $taxonomy->cap->assign_terms ) )
    2253                         return new IXR_Error( 401, __( 'You are not allowed to assign terms in this taxonomy.' ) );
     2253                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to assign terms in this taxonomy.' ) );
    22542254
    22552255                return $this->_prepare_taxonomy( $taxonomy, $fields );
    22562256        }
     
    23802380                do_action( 'xmlrpc_call', 'wp.getUser' );
    23812381
    23822382                if ( ! current_user_can( 'edit_user', $user_id ) )
    2383                         return new IXR_Error( 401, __( 'Sorry, you cannot edit users.' ) );
     2383                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit users.' ) );
    23842384
    23852385                $user_data = get_userdata( $user_id );
    23862386
     
    24382438                do_action( 'xmlrpc_call', 'wp.getUsers' );
    24392439
    24402440                if ( ! current_user_can( 'list_users' ) )
    2441                         return new IXR_Error( 401, __( 'You are not allowed to browse users.' ) );
     2441                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to browse users.' ) );
    24422442
    24432443                $query = array( 'fields' => 'all_with_meta' );
    24442444
     
    25112511                do_action( 'xmlrpc_call', 'wp.getProfile' );
    25122512
    25132513                if ( ! current_user_can( 'edit_user', $user->ID ) )
    2514                         return new IXR_Error( 401, __( 'Sorry, you cannot edit your profile.' ) );
     2514                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit your profile.' ) );
    25152515
    25162516                $user_data = get_userdata( $user->ID );
    25172517
     
    25572557                do_action( 'xmlrpc_call', 'wp.editProfile' );
    25582558
    25592559                if ( ! current_user_can( 'edit_user', $user->ID ) )
    2560                         return new IXR_Error( 401, __( 'Sorry, you cannot edit your profile.' ) );
     2560                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit your profile.' ) );
    25612561
    25622562                // holds data of the user
    25632563                $user_data = array();
     
    25912591                        return new IXR_Error( 500, $result->get_error_message() );
    25922592
    25932593                if ( ! $result )
    2594                         return new IXR_Error( 500, __( 'Sorry, the user cannot be updated.' ) );
     2594                        return new IXR_Error( 500, __( 'The user cannot be updated.' ) );
    25952595
    25962596                return true;
    25972597        }
     
    26272627                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    26282628
    26292629                if ( !current_user_can( 'edit_page', $page_id ) )
    2630                         return new IXR_Error( 401, __( 'Sorry, you cannot edit this page.' ) );
     2630                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this page.' ) );
    26312631
    26322632                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    26332633                do_action( 'xmlrpc_call', 'wp.getPage' );
     
    26682668                        return $this->error;
    26692669
    26702670                if ( !current_user_can( 'edit_pages' ) )
    2671                         return new IXR_Error( 401, __( 'Sorry, you cannot edit pages.' ) );
     2671                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit pages.' ) );
    26722672
    26732673                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    26742674                do_action( 'xmlrpc_call', 'wp.getPages' );
     
    27622762
    27632763                // Make sure the user can delete pages.
    27642764                if ( !current_user_can('delete_page', $page_id) )
    2765                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to delete this page.' ) );
     2765                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to delete this page.' ) );
    27662766
    27672767                // Attempt to delete the page.
    27682768                $result = wp_delete_post($page_id);
     
    28242824
    28252825                // Make sure the user is allowed to edit pages.
    28262826                if ( !current_user_can('edit_page', $page_id) )
    2827                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to edit this page.' ) );
     2827                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this page.' ) );
    28282828
    28292829                // Mark this as content for a page.
    28302830                $content['post_type'] = 'page';
     
    28702870                        return $this->error;
    28712871
    28722872                if ( !current_user_can( 'edit_pages' ) )
    2873                         return new IXR_Error( 401, __( 'Sorry, you cannot edit pages.' ) );
     2873                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit pages.' ) );
    28742874
    28752875                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    28762876                do_action( 'xmlrpc_call', 'wp.getPageList' );
     
    29262926                        return $this->error;
    29272927
    29282928                if ( !current_user_can('edit_posts') )
    2929                         return new IXR_Error( 401, __( 'Sorry, you cannot edit posts on this site.' ) );
     2929                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit posts on this site.' ) );
    29302930
    29312931                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    29322932                do_action( 'xmlrpc_call', 'wp.getAuthors' );
     
    29672967                        return $this->error;
    29682968
    29692969                if ( !current_user_can( 'edit_posts' ) )
    2970                         return new IXR_Error( 401, __( 'Sorry, you must be able to edit posts on this site in order to view tags.' ) );
     2970                        return new IXR_Error( 401, __( 'You must be able to edit posts on this site in order to view tags.' ) );
    29712971
    29722972                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    29732973                do_action( 'xmlrpc_call', 'wp.getKeywords' );
     
    30213021
    30223022                // Make sure the user is allowed to add a category.
    30233023                if ( !current_user_can('manage_categories') )
    3024                         return new IXR_Error(401, __('Sorry, you do not have the right to add a category.'));
     3024                        return new IXR_Error(401, __('You aren&#8217;t allowed to add a category.'));
    30253025
    30263026                // If no slug was provided make it empty so that
    30273027                // WordPress will generate one.
     
    30963096                do_action( 'xmlrpc_call', 'wp.deleteCategory' );
    30973097
    30983098                if ( !current_user_can('manage_categories') )
    3099                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to delete a category.' ) );
     3099                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to delete a category.' ) );
    31003100
    31013101                $status = wp_delete_term( $category_id, 'category' );
    31023102
     
    31433143                        return $this->error;
    31443144
    31453145                if ( !current_user_can( 'edit_posts' ) )
    3146                         return new IXR_Error( 401, __( 'Sorry, you must be able to edit posts on this site in order to view categories.' ) );
     3146                        return new IXR_Error( 401, __( 'You must be able to edit posts on this site in order to view categories.' ) );
    31473147
    31483148                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    31493149                do_action( 'xmlrpc_call', 'wp.suggestCategories' );
     
    31943194                }
    31953195
    31963196                if ( ! current_user_can( 'edit_comment', $comment_id ) ) {
    3197                         return new IXR_Error( 403, __( 'You are not allowed to moderate or edit this comment.' ) );
     3197                        return new IXR_Error( 403, __( 'You aren&#8217;t allowed to moderate or edit this comment.' ) );
    31983198                }
    31993199
    32003200                return $this->_prepare_comment( $comment );
     
    33273327                }
    33283328
    33293329                if ( !current_user_can( 'edit_comment', $comment_ID ) ) {
    3330                         return new IXR_Error( 403, __( 'You are not allowed to moderate or edit this comment.' ) );
     3330                        return new IXR_Error( 403, __( 'You aren&#8217;t allowed to moderate or edit this comment.' ) );
    33313331                }
    33323332
    33333333                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
     
    33943394                }
    33953395
    33963396                if ( ! current_user_can( 'edit_comment', $comment_ID ) ) {
    3397                         return new IXR_Error( 403, __( 'You are not allowed to moderate or edit this comment.' ) );
     3397                        return new IXR_Error( 403, __( 'You aren&#8217;t allowed to moderate or edit this comment.' ) );
    33983398                }
    33993399
    34003400                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
     
    34373437                        return new IXR_Error(500, $result->get_error_message());
    34383438
    34393439                if ( !$result )
    3440                         return new IXR_Error(500, __('Sorry, the comment could not be edited. Something wrong happened.'));
     3440                        return new IXR_Error(500, __('The comment could not be edited. Something wrong happened.'));
    34413441
    34423442                /**
    34433443                 * Fires after a comment has been successfully updated via XML-RPC.
     
    35133513                }
    35143514
    35153515                if ( ! comments_open( $post_id ) ) {
    3516                         return new IXR_Error( 403, __( 'Sorry, comments are closed for this item.' ) );
     3516                        return new IXR_Error( 403, __( 'Comments are closed for this item.' ) );
    35173517                }
    35183518
    35193519                $comment = array();
     
    38373837                        return $this->error;
    38383838
    38393839                if ( !current_user_can( 'manage_options' ) )
    3840                         return new IXR_Error( 403, __( 'You are not allowed to update options.' ) );
     3840                        return new IXR_Error( 403, __( 'You aren&#8217;t allowed to update options.' ) );
    38413841
    38423842                $option_names = array();
    38433843                foreach ( $options as $o_name => $o_value ) {
     
    38893889                        return $this->error;
    38903890
    38913891                if ( !current_user_can( 'upload_files' ) )
    3892                         return new IXR_Error( 403, __( 'You do not have permission to upload files.' ) );
     3892                        return new IXR_Error( 403, __( 'You aren&#8217;t allowed to upload files.' ) );
    38933893
    38943894                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    38953895                do_action( 'xmlrpc_call', 'wp.getMediaItem' );
     
    39373937                        return $this->error;
    39383938
    39393939                if ( !current_user_can( 'upload_files' ) )
    3940                         return new IXR_Error( 401, __( 'You do not have permission to upload files.' ) );
     3940                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to upload files.' ) );
    39413941
    39423942                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    39433943                do_action( 'xmlrpc_call', 'wp.getMediaLibrary' );
     
    40694069                $post_type = get_post_type_object( $post_type_name );
    40704070
    40714071                if ( ! current_user_can( $post_type->cap->edit_posts ) )
    4072                         return new IXR_Error( 401, __( 'Sorry, you are not allowed to edit this post type.' ) );
     4072                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post type.' ) );
    40734073
    40744074                return $this->_prepare_post_type( $post_type, $fields );
    40754075        }
     
    41854185                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    41864186
    41874187                if ( ! current_user_can( 'edit_post', $post_id ) )
    4188                         return new IXR_Error( 401, __( 'Sorry, you are not allowed to edit posts.' ) );
     4188                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit posts.' ) );
    41894189
    41904190                // Check if revisions are enabled.
    41914191                if ( ! wp_revisions_enabled( $post ) )
     
    42554255                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    42564256
    42574257                if ( ! current_user_can( 'edit_post', $revision->post_parent ) )
    4258                         return new IXR_Error( 401, __( 'Sorry, you cannot edit this post.' ) );
     4258                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    42594259
    42604260                // Check if revisions are disabled.
    42614261                if ( ! wp_revisions_enabled( $post ) )
     
    43714371                        return $this->error;
    43724372
    43734373                if ( !current_user_can( 'edit_posts' ) )
    4374                         return new IXR_Error( 401, __( 'Sorry, you do not have access to user data on this site.' ) );
     4374                        return new IXR_Error( 401, __( 'You do not have access to user data on this site.' ) );
    43754375
    43764376                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    43774377                do_action( 'xmlrpc_call', 'blogger.getUserInfo' );
     
    44174417                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    44184418
    44194419                if ( !current_user_can( 'edit_post', $post_ID ) )
    4420                         return new IXR_Error( 401, __( 'Sorry, you cannot edit this post.' ) );
     4420                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    44214421
    44224422                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    44234423                do_action( 'xmlrpc_call', 'blogger.getPost' );
     
    44704470                        return $this->error;
    44714471
    44724472                if ( ! current_user_can( 'edit_posts' ) )
    4473                         return new IXR_Error( 401, __( 'Sorry, you cannot edit posts on this site.' ) );
     4473                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit posts on this site.' ) );
    44744474
    44754475                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    44764476                do_action( 'xmlrpc_call', 'blogger.getRecentPosts' );
     
    45134513         * @return IXR_Error
    45144514         */
    45154515        public function blogger_getTemplate($args) {
    4516                 return new IXR_Error( 403, __('Sorry, that file cannot be edited.' ) );
     4516                return new IXR_Error( 403, __('That file cannot be edited.' ) );
    45174517        }
    45184518
    45194519        /**
     
    45244524         * @return IXR_Error
    45254525         */
    45264526        public function blogger_setTemplate($args) {
    4527                 return new IXR_Error( 403, __('Sorry, that file cannot be edited.' ) );
     4527                return new IXR_Error( 403, __('That file cannot be edited.' ) );
    45284528        }
    45294529
    45304530        /**
     
    45604560
    45614561                $cap = ($publish) ? 'publish_posts' : 'edit_posts';
    45624562                if ( ! current_user_can( get_post_type_object( 'post' )->cap->create_posts ) || !current_user_can($cap) )
    4563                         return new IXR_Error(401, __('Sorry, you are not allowed to post on this site.'));
     4563                        return new IXR_Error(401, __('You aren&#8217;t allowed to post on this site.'));
    45644564
    45654565                $post_status = ($publish) ? 'publish' : 'draft';
    45664566
     
    45804580                        return new IXR_Error(500, $post_ID->get_error_message());
    45814581
    45824582                if ( !$post_ID )
    4583                         return new IXR_Error(500, __('Sorry, your entry could not be posted. Something wrong happened.'));
     4583                        return new IXR_Error(500, __('Your entry could not be posted. Something wrong happened.'));
    45844584
    45854585                $this->attach_uploads( $post_ID, $post_content );
    45864586
     
    46404640                $this->escape($actual_post);
    46414641
    46424642                if ( ! current_user_can( 'edit_post', $post_ID ) ) {
    4643                         return new IXR_Error(401, __('Sorry, you do not have the right to edit this post.'));
     4643                        return new IXR_Error(401, __('You aren&#8217;t allowed to edit this post.'));
    46444644                }
    46454645                if ( 'publish' == $actual_post['post_status'] && ! current_user_can( 'publish_posts' ) ) {
    4646                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to publish this post.' ) );
     4646                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to publish this post.' ) );
    46474647                }
    46484648
    46494649                $postdata = array();
     
    47104710                }
    47114711
    47124712                if ( ! current_user_can( 'delete_post', $post_ID ) ) {
    4713                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to delete this post.' ) );
     4713                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to delete this post.' ) );
    47144714                }
    47154715
    47164716                $result = wp_delete_post( $post_ID );
     
    47974797                                        $cap  = 'publish_pages';
    47984798                                else
    47994799                                        $cap = 'edit_pages';
    4800                                 $error_message = __( 'Sorry, you are not allowed to publish pages on this site.' );
     4800                                $error_message = __( 'You aren&#8217;t allowed to publish pages on this site.' );
    48014801                                $post_type = 'page';
    48024802                                if ( !empty( $content_struct['wp_page_template'] ) )
    48034803                                        $page_template = $content_struct['wp_page_template'];
     
    48084808                                        $cap  = 'publish_posts';
    48094809                                else
    48104810                                        $cap = 'edit_posts';
    4811                                 $error_message = __( 'Sorry, you are not allowed to publish posts on this site.' );
     4811                                $error_message = __( 'You aren&#8217;t allowed to publish posts on this site.' );
    48124812                                $post_type = 'post';
    48134813                        } else {
    48144814                                // No other post_type values are allowed here
     
    48214821                                $cap  = 'publish_posts';
    48224822                        else
    48234823                                $cap = 'edit_posts';
    4824                         $error_message = __( 'Sorry, you are not allowed to publish posts on this site.' );
     4824                        $error_message = __( 'You aren&#8217;t allowed to publish posts on this site.' );
    48254825                        $post_type = 'post';
    48264826                }
    48274827
    48284828                if ( ! current_user_can( get_post_type_object( $post_type )->cap->create_posts ) )
    4829                         return new IXR_Error( 401, __( 'Sorry, you are not allowed to publish posts on this site.' ) );
     4829                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to publish posts on this site.' ) );
    48304830                if ( !current_user_can( $cap ) )
    48314831                        return new IXR_Error( 401, $error_message );
    48324832
     
    48634863                        switch ( $post_type ) {
    48644864                                case "post":
    48654865                                        if ( !current_user_can( 'edit_others_posts' ) )
    4866                                                 return new IXR_Error( 401, __( 'You are not allowed to create posts as this user.' ) );
     4866                                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to create posts as this user.' ) );
    48674867                                        break;
    48684868                                case "page":
    48694869                                        if ( !current_user_can( 'edit_others_pages' ) )
    4870                                                 return new IXR_Error( 401, __( 'You are not allowed to create pages as this user.' ) );
     4870                                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to create pages as this user.' ) );
    48714871                                        break;
    48724872                                default:
    48734873                                        return new IXR_Error( 401, __( 'Invalid post type' ) );
     
    50395039                        return new IXR_Error(500, $post_ID->get_error_message());
    50405040
    50415041                if ( !$post_ID )
    5042                         return new IXR_Error(500, __('Sorry, your entry could not be posted. Something wrong happened.'));
     5042                        return new IXR_Error(500, __('Your entry could not be posted. Something wrong happened.'));
    50435043
    50445044                /**
    50455045                 * Fires after a new post has been successfully created via the XML-RPC MovableType API.
     
    51405140                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    51415141
    51425142                if ( ! current_user_can( 'edit_post', $post_ID ) )
    5143                         return new IXR_Error( 401, __( 'Sorry, you do not have the right to edit this post.' ) );
     5143                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    51445144
    51455145                // Use wp.editPost to edit post types other than post and page.
    51465146                if ( ! in_array( $postdata[ 'post_type' ], array( 'post', 'page' ) ) )
     
    51995199                                switch ( $post_type ) {
    52005200                                        case 'post':
    52015201                                                if ( ! current_user_can( 'edit_others_posts' ) ) {
    5202                                                         return new IXR_Error( 401, __( 'You are not allowed to change the post author as this user.' ) );
     5202                                                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to change the post author as this user.' ) );
    52035203                                                }
    52045204                                                break;
    52055205                                        case 'page':
    52065206                                                if ( ! current_user_can( 'edit_others_pages' ) ) {
    5207                                                         return new IXR_Error( 401, __( 'You are not allowed to change the page author as this user.' ) );
     5207                                                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to change the page author as this user.' ) );
    52085208                                                }
    52095209                                                break;
    52105210                                        default:
     
    53115311
    53125312                if ( 'publish' == $post_status || 'private' == $post_status ) {
    53135313                        if ( 'page' == $post_type && ! current_user_can( 'publish_pages' ) ) {
    5314                                 return new IXR_Error( 401, __( 'Sorry, you do not have the right to publish this page.' ) );
     5314                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to publish this page.' ) );
    53155315                        } elseif ( ! current_user_can( 'publish_posts' ) ) {
    5316                                 return new IXR_Error( 401, __( 'Sorry, you do not have the right to publish this post.' ) );
     5316                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to publish this post.' ) );
    53175317                        }
    53185318                }
    53195319
     
    53505350                        return new IXR_Error(500, $result->get_error_message());
    53515351
    53525352                if ( !$result )
    5353                         return new IXR_Error(500, __('Sorry, your entry could not be edited. Something wrong happened.'));
     5353                        return new IXR_Error(500, __('Your entry could not be edited. Something wrong happened.'));
    53545354
    53555355                // Only posts can be sticky
    53565356                if ( $post_type == 'post' && isset( $content_struct['sticky'] ) ) {
     
    54315431                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    54325432
    54335433                if ( !current_user_can( 'edit_post', $post_ID ) )
    5434                         return new IXR_Error( 401, __( 'Sorry, you cannot edit this post.' ) );
     5434                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    54355435
    54365436                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    54375437                do_action( 'xmlrpc_call', 'metaWeblog.getPost' );
     
    55615561                        return $this->error;
    55625562
    55635563                if ( ! current_user_can( 'edit_posts' ) )
    5564                         return new IXR_Error( 401, __( 'Sorry, you cannot edit posts on this site.' ) );
     5564                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit posts on this site.' ) );
    55655565
    55665566                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    55675567                do_action( 'xmlrpc_call', 'metaWeblog.getRecentPosts' );
     
    56745674                        return $this->error;
    56755675
    56765676                if ( !current_user_can( 'edit_posts' ) )
    5677                         return new IXR_Error( 401, __( 'Sorry, you must be able to edit posts on this site in order to view categories.' ) );
     5677                        return new IXR_Error( 401, __( 'You must be able to edit posts on this site in order to view categories.' ) );
    56785678
    56795679                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    56805680                do_action( 'xmlrpc_call', 'metaWeblog.getCategories' );
     
    57385738                do_action( 'xmlrpc_call', 'metaWeblog.newMediaObject' );
    57395739
    57405740                if ( !current_user_can('upload_files') ) {
    5741                         $this->error = new IXR_Error( 401, __( 'You do not have permission to upload files.' ) );
     5741                        $this->error = new IXR_Error( 401, __( 'You aren&#8217;t allowed to upload files.' ) );
    57425742                        return $this->error;
    57435743                }
    57445744
    57455745                if ( is_multisite() && upload_is_user_over_quota( false ) ) {
    5746                         $this->error = new IXR_Error( 401, __( 'Sorry, you have used your space allocation.' ) );
     5746                        $this->error = new IXR_Error( 401, __( 'You have used your space allocation.' ) );
    57475747                        return $this->error;
    57485748                }
    57495749
     
    57725772                        $post_id = (int) $data['post_id'];
    57735773
    57745774                        if ( ! current_user_can( 'edit_post', $post_id ) )
    5775                                 return new IXR_Error( 401, __( 'Sorry, you cannot edit this post.' ) );
     5775                                return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    57765776                }
    57775777                $attachment = array(
    57785778                        'post_title' => $name,
     
    58955895                        return $this->error;
    58965896
    58975897                if ( !current_user_can( 'edit_posts' ) )
    5898                         return new IXR_Error( 401, __( 'Sorry, you must be able to edit posts on this site in order to view categories.' ) );
     5898                        return new IXR_Error( 401, __( 'You must be able to edit posts on this site in order to view categories.' ) );
    58995899
    59005900                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    59015901                do_action( 'xmlrpc_call', 'mt.getCategoryList' );
     
    59435943                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    59445944
    59455945                if ( !current_user_can( 'edit_post', $post_ID ) )
    5946                         return new IXR_Error( 401, __( 'Sorry, you can not edit this post.' ) );
     5946                        return new IXR_Error( 401, __( 'You aren&#8217;t allowed to edit this post.' ) );
    59475947
    59485948                /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
    59495949                do_action( 'xmlrpc_call', 'mt.getPostCategories' );
     
    59975997                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    59985998
    59995999                if ( !current_user_can('edit_post', $post_ID) )
    6000                         return new IXR_Error(401, __('Sorry, you cannot edit this post.'));
     6000                        return new IXR_Error(401, __('You aren&#8217;t allowed to edit this post.'));
    60016001
    60026002                $catids = array();
    60036003                foreach ( $categories as $cat ) {
     
    61166116                        return new IXR_Error( 404, __( 'Invalid post ID.' ) );
    61176117
    61186118                if ( !current_user_can('publish_posts') || !current_user_can('edit_post', $post_ID) )
    6119                         return new IXR_Error(401, __('Sorry, you cannot publish this post.'));
     6119                        return new IXR_Error(401, __('You aren&#8217;t allowed to publish this post.'));
    61206120
    61216121                $postdata['post_status'] = 'publish';
    61226122
  • wp-includes/rest-api/class-wp-rest-server.php

     
    812812                                                if ( is_wp_error( $permission ) ) {
    813813                                                        $response = $permission;
    814814                                                } else if ( false === $permission || null === $permission ) {
    815                                                         $response = new WP_Error( 'rest_forbidden', __( "You don't have permission to do this." ), array( 'status' => 403 ) );
     815                                                        $response = new WP_Error( 'rest_forbidden', __( 'You aren&#8217;t allowed to do this.' ), array( 'status' => 403 ) );
    816816                                                }
    817817                                        }
    818818                                }
  • wp-includes/revision.php

     
    523523                $id = (int) $_GET['preview_id'];
    524524
    525525                if ( false === wp_verify_nonce( $_GET['preview_nonce'], 'post_preview_' . $id ) )
    526                         wp_die( __('You do not have permission to preview drafts.') );
     526                        wp_die( __( 'You aren&#8217;t allowed to preview drafts.' ) );
    527527
    528528                add_filter('the_preview', '_set_preview');
    529529        }
  • wp-includes/script-loader.php

     
    129129
    130130        $scripts->add( 'wp-ajax-response', "/wp-includes/js/wp-ajax-response$suffix.js", array('jquery'), false, 1 );
    131131        did_action( 'init' ) && $scripts->localize( 'wp-ajax-response', 'wpAjax', array(
    132                 'noPerm' => __('You do not have permission to do that.'),
     132                'noPerm' => __('You aren&#8217;t allowed to do that.'),
    133133                'broken' => __('An unidentified error has occurred.')
    134134        ) );
    135135
     
    438438                'cancel'             => __( 'Cancel' ),
    439439                'close'              => __( 'Close' ),
    440440                'cheatin'            => __( 'Cheatin&#8217; uh?' ),
    441                 'notAllowed'         => __( 'You are not allowed to customize the appearance of this site.' ),
     441                'notAllowed'         => __( 'You aren&#8217;t allowed to customize the appearance of this site.' ),
    442442                'previewIframeTitle' => __( 'Site Preview' ),
    443443                'loginIframeTitle'   => __( 'Session expired' ),
    444444                'collapseSidebar'    => __( 'Collapse Sidebar' ),
     
    476476        if ( is_admin() ) {
    477477                $scripts->add( 'admin-tags', "/wp-admin/js/tags$suffix.js", array( 'jquery', 'wp-ajax-response' ), false, 1 );
    478478                did_action( 'init' ) && $scripts->localize( 'admin-tags', 'tagsl10n', array(
    479                         'noPerm' => __('You do not have permission to do that.'),
     479                        'noPerm' => __('You aren&#8217;t allowed to do that.'),
    480480                        'broken' => __('An unidentified error has occurred.')
    481481                ));
    482482