Untranslated strings in plugin v 3.0.8
-
There are still a couple of untranslateable strings in admin/post.php in function wpmem_block_meta().
And once you’re at it you might want to remove the strtolower in line 225 – not all languages reserve capital letters for sentence beginnings and names only.
The funtion should look like this to enable full translation:
function wpmem_block_meta() { global $post, $wpmem; wp_nonce_field( 'wpmem_block_meta_nonce', 'wpmem_block_meta_nonce' ); $post_type = get_post_type_object( $post->post_type ); if ( isset( $wpmem->block[ $post->post_type ] ) && $wpmem->block[ $post->post_type ] == 1 ) { $block = 0; $notice_text = __('blocked'); $text = __('Unblock'); } else { //} elseif ( $wpmem->block[ $post->post_type ] == 0 ) { $block = 1; $notice_text = __('not blocked'); $text = __('Block'); } $meta = '_wpmem_block'; $admin_url = get_admin_url(); ?> <p> <?php printf( __('%s are %s by default.'), $post_type->labels->name, $notice_text ); echo ' '; printf( '<a href="%s/options-general.php?page=wpmem-settings">'. __('Edit') . '</a>', $admin_url ); ?> </p> <p> <?php if( $block == 1 ) { ?> <input type="checkbox" id="wpmem_block" name="wpmem_block" value="1" <?php checked( get_post_meta( $post->ID, $meta, true ), '1' ); ?> /> <?php } else { ?> <input type="checkbox" id="wpmem_block" name="wpmem_block" value="0" <?php checked( get_post_meta( $post->ID, $meta, true ), '0' ); ?> /> <?php } ?> <label for="wpmem_block"><?php printf( __('%s this %s'), $text, $post_type->labels->singular_name ); ?></label> </p> <?php /** * Fires after the post block meta box. * * Allows actions at the end of the block meta box on pages and posts. * * @since 2.8.8 * * @param $post object The WP Post Object. * @param $block boolean The WP-Members block value. */ do_action( 'wpmem_admin_after_block_meta', $post, $block ); }
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Untranslated strings in plugin v 3.0.8’ is closed to new replies.