Clean up secret_salt_warning. Use stronger version of wp_generate_password. Shrink line-height of #update-nag so multiple-line messages don't look so awful, use padding instead.

git-svn-id: http://svn.automattic.com/wordpress/trunk@14318 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
nacin 2010-04-30 15:25:54 +00:00
parent d08414276a
commit bb3f1f5f45
4 changed files with 10 additions and 8 deletions

File diff suppressed because one or more lines are too long

View File

@ -808,7 +808,8 @@ td.media-icon img {
}
#update-nag {
line-height: 29px;
line-height: 19px;
padding: 5px 0;
font-size: 12px;
text-align: center;
margin: 0 6px;

View File

@ -660,15 +660,16 @@ function mu_dropdown_languages( $lang_files = array(), $current = '' ) {
function secret_salt_warning() {
if ( !is_super_admin() )
return;
$secret_keys = array( 'NONCE_KEY', 'NONCE_SALT', 'AUTH_KEY', 'AUTH_SALT', 'LOGGED_IN_KEY', 'LOGGED_IN_SALT', 'SECURE_AUTH_KEY', 'SECURE_AUTH_SALT' );
$secret_keys = array( 'AUTH_KEY', 'SECURE_KEY', 'LOGGED_IN_KEY', 'NONCE_KEY', 'AUTH_SALT', 'SECURE_SALT', 'LOGGED_IN_SALT', 'NONCE_SALT' );
$out = '';
foreach( $secret_keys as $key ) {
if ( !defined( $key ) )
$out .= "define( '$key', '" . wp_generate_password() . wp_generate_password() . "' );<br />";
if ( ! defined( $key ) )
$out .= "define( '$key', '" . esc_html( wp_generate_password( 64, true, true ) ) . "' );<br />";
}
if ( $out != '' ) {
$msg = sprintf( __( 'Warning! WordPress encrypts user cookies, but you must add the following lines to <strong>%swp-config.php</strong> for it to be more secure.<br />Please add the code before the line, <code>/* That\'s all, stop editing! Happy blogging. */</code>' ), ABSPATH );
$msg .= "<blockquote>$out</blockquote>";
$msg = __( 'Warning! WordPress encrypts user cookies, but you must add the following lines to <strong>wp-config.php</strong> for it to be more secure.' );
$msg .= '<br/>' . __( "Before the line <code>/* That's all, stop editing! Happy blogging. */</code> please add this code:" );
$msg .= "<br/><br/><code>$out</code>";
echo "<div id='update-nag'>$msg</div>";
}

View File

@ -442,7 +442,7 @@ function wp_default_styles( &$styles ) {
// Any rtl stylesheets that don't have a .dev version for ltr
$no_suffix = array( 'farbtastic' );
$styles->add( 'wp-admin', "/wp-admin/css/wp-admin$suffix.css", array(), '20100429' );
$styles->add( 'wp-admin', "/wp-admin/css/wp-admin$suffix.css", array(), '20100430' );
$styles->add( 'ie', "/wp-admin/css/ie$suffix.css", array(), '20100219' );
$styles->add_data( 'ie', 'conditional', 'lte IE 7' );