From 6c8ec25985e7ac5a913952fbecc003a46b8c46e6 Mon Sep 17 00:00:00 2001 From: ryan Date: Wed, 26 May 2010 03:36:04 +0000 Subject: [PATCH] Post and page help. see #13467 git-svn-id: http://svn.automattic.com/wordpress/trunk@14929 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/edit-form-advanced.php | 21 ++++++++++++++++++--- wp-admin/edit.php | 19 ++++++++++++++++--- wp-admin/includes/template.php | 19 ++++++------------- 3 files changed, 40 insertions(+), 19 deletions(-) diff --git a/wp-admin/edit-form-advanced.php b/wp-admin/edit-form-advanced.php index fb3447c46..45284e840 100644 --- a/wp-admin/edit-form-advanced.php +++ b/wp-admin/edit-form-advanced.php @@ -165,15 +165,30 @@ do_action('do_meta_boxes', $post_type, 'normal', $post); do_action('do_meta_boxes', $post_type, 'advanced', $post); do_action('do_meta_boxes', $post_type, 'side', $post); -add_contextual_help($current_screen, '

' . __('The title field and the big Post Editing Area are fixed in place, but you can reposition all the other boxes that allow you to add metadata to your post using drag and drop, and can minimize or expand them by clicking the title bar of the box. You can also hide any of the boxes by using the Screen Options tab, where you can also choose a 1- or 2-column layout for this screen.') . '

' . +if ( 'post' == $post_type ) { + add_contextual_help($current_screen, '

' . __('The title field and the big Post Editing Area are fixed in place, but you can reposition all the other boxes that allow you to add metadata to your post using drag and drop, and can minimize or expand them by clicking the title bar of the box. You can also hide any of the boxes by using the Screen Options tab, where you can also choose a 1- or 2-column layout for this screen.') . '

' . '

' . __('Title - Enter a title for your post. After you enter a title, you’ll see the permalink below, which you can edit.') . '

' . '

' . __('Post editor - Enter the text for you post. There are two modes of editing: Visual and HTML. Choose the mode by clicking on the appropriate tab. Visual mode gives you a WYSIWYG editor. Click the last icon in the row to get a second row of controls. The HTML mode allows you to enter raw HTML along with your post text. You can insert media files by clicking the icons above the post editor and following the directions.') . '

' . '

' . __('Publish - You can set the terms of publishing your post in the Publish box. For Status, Visibility, and Publish (immediately), click on the Edit link to reveal more options. Visibility includes options for password-protecting a post or making it stay at the top of your blog indefinitely (sticky). Publish (immediately) allows you to set a future or past date and time, so you can schedule a post to be published in the future or backdate a post.') . '

' . '

' . __('Featured Image - This allows you to associate an image with your post without inserting it. This is usually useful only if your theme makes use of the featured image as a post thumbnail on the home page, a custom header, etc.') . '

' . '

' . __('Send Trackbacks - Trackbacks are a way to notify legacy blog systems that you’ve linked to them. Enter the URL(s) you want to send trackbacks. If you link other WordPress sites they’ll be notified automatically using pingbacks, and this field is unnecessary.') . '

' . '

' . __('Discussion - You can turn comments and pings on or off, and if there are comments on the post, you can see them here and moderate them.') . '

' . - '

' . sprintf(__('You can also create posts with the Press This bookmarklet.'), 'tools.php') . '

' -); + '

' . sprintf(__('You can also create posts with the Press This bookmarklet.'), 'tools.php') . '

' . + '

' . __('For more information:') . '

' . + '

' . sprintf(__('Writing Posts Documentation'), 'http://codex.wordpress.org/Writing_Posts') . '

' . + '

' . sprintf(__('Support Forums'), 'http://wordpress.org/support/') . '

' + ); +} elseif ( 'page' == $post_type ) { + add_contextual_help($current_screen, '

' . __('Pages are similar to to Posts in that they have a title, body text, and associated metadata, but they are different in that they are not part of the chronological blog stream, kind of like permanent posts. Pages are not categorized or tagged, but can have a hierarchy. You can nest Pages under other Pages by making one the "Parent" of the other, creating a group of Pages.') . '

' . + '

' . __('Creating a Page is very similar to creating a Post, and the screens can be customized in the same way using drag and drop, the Screen Options tab, and expanding/collapsing boxes as you choose. The Page editor mostly works the same Post editor, but there are some Page-specific features in the Attributes box:') . '

' . + '

' . __('Parent - You can arrange your pages in hierarchies. For example, you could have an “About” page that has “Life Story” and “My Dog” pages under it. There are no limits to how many levels you can nest pages.') . '

' . + '

' . __('Template - Some themes have custom templates you can use for certain pages that might have additional features or custom layouts. If so, you’ll see them in this dropdown menu.') . '

' . + '

' . __('Order - Pages are usually ordered alphabetically, but you can put a number above to change the order pages appear in.') . '

' . + '

' . __('For more information:') . '

' . + '

' . sprintf(__('Page Creation Documentation'), 'http://codex.wordpress.org/Pages_Add_New_SubPanel') . '

' . + '

' . sprintf(__('Support Forums'), 'http://wordpress.org/support/') . '

' + ); +} require_once('./admin-header.php'); ?> diff --git a/wp-admin/edit.php b/wp-admin/edit.php index 73e3b7396..349b9edd3 100644 --- a/wp-admin/edit.php +++ b/wp-admin/edit.php @@ -156,7 +156,8 @@ else $title = $post_type_object->labels->name; -add_contextual_help($current_screen, '

' . __('You can customize the display of this screen in a number of ways:') . '

' . +if ( 'post' == $post_type ) { + add_contextual_help($current_screen, '

' . __('You can customize the display of this screen in a number of ways:') . '

' . '' . - '

' . __('You can also edit multiple posts at once. Select the posts you want to edit using the checkboxes, select Edit from the Bulk Actions menu and click Apply. You will be able to change the metadata (categories, author, etc.) for all selected posts at once. To remove a post from the grouping, just click the x next to its name in the Bulk Edit area that appears.') . '

' -); + '

' . __('You can also edit multiple posts at once. Select the posts you want to edit using the checkboxes, select Edit from the Bulk Actions menu and click Apply. You will be able to change the metadata (categories, author, etc.) for all selected posts at once. To remove a post from the grouping, just click the x next to its name in the Bulk Edit area that appears.') . '

' . + '

' . __('For more information:') . '

' . + '

' . sprintf(__('Edit Posts Documentation'), 'http://codex.wordpress.org/Posts_Edit_SubPanel') . '

' . + '

' . sprintf(__('Support Forums'), 'http://wordpress.org/support/') . '

' + ); +} elseif ( 'page' == $post_type ) { + add_contextual_help($current_screen, '

' . __('Pages are similar to to Posts in that they have a title, body text, and associated metadata, but they are different in that they are not part of the chronological blog stream, kind of like permanent posts. Pages are not categorized or tagged, but can have a hierarchy. You can nest Pages under other Pages by making one the "Parent" of the other, creating a group of Pages.') . '

' . + '

' . __('Managing Pages is very similar to managing Posts, and the screens can be customized in the same way. ') . '

' . + '

' . __('You can also perform the same types of actions, including narrowing the list by using the filters, acting on a Page using the action links that appear when you hover over a row, or using the Bulk Actions menu to edit the metadata for multiple Pages at once.') . '

' . + '

' . __('For more information:') . '

' . + '

' . sprintf(__('Page Management Documentation'), 'http://codex.wordpress.org/Pages_Edit_SubPanel') . '

' . + '

' . sprintf(__('Support Forums'), 'http://wordpress.org/support/') . '

' + ); +} require_once('./admin-header.php'); diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index a27c0a0a0..0c756b820 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -3634,23 +3634,16 @@ function screen_meta($screen) { id]) ) { - if ( !empty($title) ) - $contextual_help .= '
' . sprintf(__('Get help with “%s”'), $title) . '
'; - else - $contextual_help .= '
' . __('Get help with this page') . '
'; $contextual_help .= '
' . $_wp_contextual_help[$screen->id] . "
\n"; - - $contextual_help .= '
' . __('Other Help') . '
'; } else { - $contextual_help .= '
' . __('Help') . '
'; + $contextual_help .= '
'; + $default_help = __('Documentation'); + $default_help .= '
'; + $default_help .= __('Support Forums'); + $contextual_help .= apply_filters('default_contextual_help', $default_help); + $contextual_help .= "
\n"; } - $contextual_help .= '
'; - $default_help = __('Documentation'); - $default_help .= '
'; - $default_help .= __('Support Forums'); - $contextual_help .= apply_filters('default_contextual_help', $default_help); - $contextual_help .= "
\n"; echo apply_filters('contextual_help', $contextual_help, $screen->id, $screen); ?>