Show theme install help text only if user has install_themes cap.

git-svn-id: https://develop.svn.wordpress.org/trunk@11285 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2009-05-11 23:42:46 +00:00
parent b52feaaa0f
commit cf14056f90

View File

@ -29,8 +29,10 @@ $title = __('Manage Themes');
$parent_file = 'themes.php';
$help = '<p>' . __('Themes give your WordPress style. Once a theme is installed, you may preview it, activate it or deactivate it here.') . '</p>';
$help .= '<p>' . sprintf(__('You can find additional themes for your site by using the new <a href="%1$s">Theme Browser/Installer</a> functionality or by browsing the <a href="http://wordpress.org/extend/themes/">WordPress Theme Directory</a> directly and installing manually. To install a theme <em>manually</em>, <a href="%2$s">upload its ZIP archive with the new uploader</a> or copy its folder via FTP into your <code>wp-content/themes</code> directory.'), 'theme-install.php', 'theme-install.php?tab=upload' ) . '</p>';
$help .= '<p>' . __('Once a theme is uploaded, you should see it on this page.') . '</p>' ;
if ( current_user_can('install_themes') ) {
$help .= '<p>' . sprintf(__('You can find additional themes for your site by using the new <a href="%1$s">Theme Browser/Installer</a> functionality or by browsing the <a href="http://wordpress.org/extend/themes/">WordPress Theme Directory</a> directly and installing manually. To install a theme <em>manually</em>, <a href="%2$s">upload its ZIP archive with the new uploader</a> or copy its folder via FTP into your <code>wp-content/themes</code> directory.'), 'theme-install.php', 'theme-install.php?tab=upload' ) . '</p>';
$help .= '<p>' . __('Once a theme is uploaded, you should see it on this page.') . '</p>' ;
}
add_contextual_help('themes', $help);