Strip trailing whitespace

git-svn-id: https://develop.svn.wordpress.org/trunk@10150 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2008-12-09 18:03:31 +00:00
parent f0f4bd82b2
commit baaaa352ba
96 changed files with 336 additions and 336 deletions

View File

@@ -427,10 +427,10 @@ case 'get-tagcloud' :
die('-1');
$tags = get_tags( array( 'number' => 45, 'orderby' => 'count', 'order' => 'DESC' ) );
if ( empty( $tags ) )
die( __('No tags found!') );
foreach ( $tags as $key => $tag ) {
$tags[ $key ]->link = '#';
$tags[ $key ]->id = $tag->term_id;
@@ -440,9 +440,9 @@ case 'get-tagcloud' :
if ( empty($return) )
die('0');
echo $return;
exit;
break;
case 'add-comment' :

View File

@@ -22,7 +22,7 @@ if ( isset( $_POST['deletecomment'] ) )
*
* @param string $msg Error Message. Assumed to contain HTML and be sanitized.
*/
function comment_footer_die( $msg ) { //
function comment_footer_die( $msg ) { //
echo "<div class='wrap'><p>$msg</p></div>";
include('admin-footer.php');
die;

View File

@@ -106,7 +106,7 @@ li.widget-list-control-item h4.widget-title a,
#dragHelper li.widget-list-control-item h4.widget-title a,
#draghelper li.widget-list-control-item h4.widget-title a:visited,
.login #backtoblog a:hover,
#plugin-information .action-button a,
#plugin-information .action-button a,
#plugin-information .action-button a:hover,
#plugin-information .action-button a:visited {
color: #fff;
@@ -342,7 +342,7 @@ a:focus {
color: #d54e21;
}
a:hover,
a:hover,
#wphead #viewsite a:hover,
#adminmenu a:hover,
#adminmenu ul.wp-submenu a:hover,
@@ -625,17 +625,17 @@ li.widget-list-control-item h4,
background-color: #ffffe0;
}
#the-comment-list .approve a {
color: #006505;
}
#the-comment-list .approve a {
color: #006505;
}
#the-comment-list .unapprove a {
color: #d98500;
}
#the-comment-list .unapprove a {
color: #d98500;
}
#the-comment-list .delete a {
color: #bc0b0b;
}
#the-comment-list .delete a {
color: #bc0b0b;
}
.plugins tr {
background-color: #fff;

View File

@@ -106,7 +106,7 @@ li.widget-list-control-item h4.widget-title a,
#dragHelper li.widget-list-control-item h4.widget-title a,
#draghelper li.widget-list-control-item h4.widget-title a:visited,
.login #backtoblog a:hover,
#plugin-information .action-button a,
#plugin-information .action-button a,
#plugin-information .action-button a:hover,
#plugin-information .action-button a:visited {
color: #fff;
@@ -342,7 +342,7 @@ a:focus {
color: #d54e21;
}
a:hover,
a:hover,
#wphead #viewsite a:hover,
#adminmenu a:hover,
#adminmenu ul.wp-submenu a:hover,
@@ -625,17 +625,17 @@ li.widget-list-control-item h4,
background-color: #ffffe0;
}
#the-comment-list .approve a {
color: #006505;
}
#the-comment-list .approve a {
color: #006505;
}
#the-comment-list .unapprove a {
color: #d98500;
}
#the-comment-list .unapprove a {
color: #d98500;
}
#the-comment-list .delete a {
color: #bc0b0b;
}
#the-comment-list .delete a {
color: #bc0b0b;
}
.plugins tr {
background-color: #fff;

View File

@@ -188,7 +188,7 @@ div.postbox div.inside {
clear: right;
position: relative;
top: -5px;
padding: 2px 11px;
padding: 2px 11px;
}
/* Recent Comments */

View File

@@ -27,6 +27,6 @@
width: 17px;
height: 17px;
margin: -8px 0 0 -8px;
overflow: hidden;
overflow: hidden;
background: url(../images/marker.png) no-repeat;
}

View File

@@ -72,7 +72,7 @@ table {
#wpbody {
clear: both;
margin-left: 175px;
}
}
.folded #wpbody {
margin-left: 60px;

View File

@@ -50,7 +50,7 @@ div#dashboard-widgets {
.widefat th input {
margin: 0 5px 0 0;
}
/* ---------- add by navid */
/* ---------- add by navid */
#TB_window {
width: 670px;
position: absolute;

View File

@@ -88,6 +88,6 @@ button.dismiss {
margin-right: 0;
margin-left: 15px;
}
#gallery-settings .align .field label {
#gallery-settings .align .field label {
margin: 0 0 0 1.5em;
}

View File

@@ -146,24 +146,24 @@ class Custom_Image_Header {
jQuery('#textcolor').val(color);
farbtastic.setColor(color);
}
jQuery(document).ready(function() {
jQuery('#pickcolor').click(function() {
jQuery('#colorPickerDiv').show();
});
jQuery('#hidetext').click(function() {
toggle_text();
});
farbtastic = jQuery.farbtastic('#colorPickerDiv', function(color) { pickColor(color); });
pickColor('#<?php echo get_theme_mod('header_textcolor', HEADER_TEXTCOLOR); ?>');
<?php if ( 'blank' == get_theme_mod('header_textcolor', HEADER_TEXTCOLOR) ) { ?>
toggle_text();
<?php } ?>
});
jQuery(document).mousedown(function(){
// Make the picker disappear, since we're using it in an independant div
hide_picker();

View File

@@ -15,13 +15,13 @@ if ( have_posts() ) { ?>
<?php print_column_headers('upload'); ?>
</tr>
</thead>
<tfoot>
<tr>
<?php print_column_headers('upload', false); ?>
</tr>
</tfoot>
<tbody id="the-list" class="list:post">
<?php
add_filter('the_title','wp_specialchars');
@@ -207,4 +207,4 @@ foreach ($posts_columns as $column_name => $column_display_name ) {
<?php
} // end if ( have_posts() )
?>

View File

@@ -20,7 +20,7 @@ if ( ( isset( $_REQUEST['delete_all_spam'] ) || isset( $_REQUEST['delete_all_spa
$delete_time = $wpdb->escape( $_REQUEST['pagegen_timestamp'] );
$deleted_spam = $wpdb->query( "DELETE FROM $wpdb->comments WHERE comment_approved = 'spam' AND '$delete_time' > comment_date_gmt" );
$redirect_to = 'edit-comments.php?comment_status=spam&deleted=' . (int) $deleted_spam;
$redirect_to = 'edit-comments.php?comment_status=spam&deleted=' . (int) $deleted_spam;
if ( $post_id )
$redirect_to = add_query_arg( 'p', absint( $post_id ), $redirect_to );
wp_redirect( $redirect_to );

View File

@@ -109,7 +109,7 @@ $date = date_i18n( $datef, strtotime( $comment->comment_date ) );
$url = get_comment_author_url();
if ( ! empty( $url ) && 'http://' != $url ) {
$link = "<a href='$url' rel='external nofollow' target='_blank'>" . __('visit site') . "</a>";
printf( __( 'URL (%s):' ), apply_filters('get_comment_author_link', $link ) );
printf( __( 'URL (%s):' ), apply_filters('get_comment_author_link', $link ) );
} else {
_e( 'URL:' );
} ?></td>

View File

@@ -333,7 +333,7 @@ function link_advanced_meta_box($link) {
</table>
<?php
}
add_meta_box('linkadvanceddiv', __('Advanced'), 'link_advanced_meta_box', 'link', 'normal', 'core');
add_meta_box('linkadvanceddiv', __('Advanced'), 'link_advanced_meta_box', 'link', 'normal', 'core');
do_action('do_meta_boxes', 'link', 'normal', $link);
do_action('do_meta_boxes', 'link', 'advanced', $link);
@@ -346,7 +346,7 @@ require_once ('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php if ( isset( $_GET['added'] ) ) : ?>
<div id="message" class="updated fade"><p><?php _e('Link added.'); ?></p></div>
@@ -365,7 +365,7 @@ wp_nonce_field( 'meta-box-order', 'meta-box-order-nonce', false ); ?>
<div id="poststuff" class="metabox-holder">
<div id="side-info-column" class="inner-sidebar">
<?php
<?php
do_action('submitlink_box');
$side_meta_boxes = do_meta_boxes( 'link', 'side', $link );
@@ -399,7 +399,7 @@ $side_meta_boxes = do_meta_boxes( 'link', 'side', $link );
</div>
</div>
<?php
<?php
do_meta_boxes('link', 'normal', $link);

View File

@@ -161,7 +161,7 @@ if ( empty($pagenum) )
$pagenum = 1;
$tagsperpage = apply_filters("tagsperpage",20);
$page_links = paginate_links( array(
'base' => add_query_arg( 'pagenum', '%#%' ),
'format' => '',
@@ -239,9 +239,9 @@ if ( $page_links )
<div class="tagcloud">
<h3><?php _e('Popular Tags'); ?></h3>
<?php
<?php
if ( $can_manage )
wp_tag_cloud(array('link' => 'edit'));
wp_tag_cloud(array('link' => 'edit'));
else
wp_tag_cloud();
?>

View File

@@ -24,7 +24,7 @@ require_once ('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<p><?php _e('When you click the button below WordPress will create an XML file for you to save to your computer.'); ?></p>
<p><?php _e('This format, which we call WordPress eXtended RSS or WXR, will contain your posts, pages, comments, custom fields, categories, and tags.'); ?></p>

View File

@@ -15,7 +15,7 @@ $parent_file = 'tools.php';
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<p><?php _e('If you have posts or comments in another system, WordPress can import those into this blog. To get started, choose a system to import from below:'); ?></p>
<?php

View File

@@ -90,7 +90,7 @@ class WP_Filesystem_Base {
function wp_themes_dir() {
return $this->wp_content_dir() . '/themes';
}
/**
* Locates a folder on the remote filesystem.
*
@@ -136,7 +136,7 @@ class WP_Filesystem_Base {
*
* @since 2.7
* @access public
*
*
* @param string $folder the folder to locate
* @return string The location of the remote path.
*/
@@ -164,7 +164,7 @@ class WP_Filesystem_Base {
*
* @since 2.7
* @access private
*
*
* @param string $folder the folder to locate
* @param string $base the folder to start searching from
* @param bool $loop if the function has recursed, Internal use only

View File

@@ -79,10 +79,10 @@ class WP_Filesystem_FTPext extends WP_Filesystem_Base {
$this->errors->add('auth', sprintf(__('Username/Password incorrect for %s'), $this->options['username']));
return false;
}
//Set the Connection to use Passive FTP
@ftp_pasv( $this->link, true );
@ftp_pasv( $this->link, true );
return true;
}

View File

@@ -90,12 +90,12 @@ class WP_Filesystem_SSH2 extends WP_Filesystem_Base {
$this->options['username'] = $opt['username'];
if ( ( !empty ($opt['public_key']) ) && ( !empty ($opt['private_key']) ) ) {
$this->options['public_key'] = $opt['public_key'];
$this->options['public_key'] = $opt['public_key'];
$this->options['private_key'] = $opt['private_key'];
$this->options['hostkey'] = array("hostkey" => "ssh-rsa");
$this->keys = true;
$this->keys = true;
}
@@ -105,18 +105,18 @@ class WP_Filesystem_SSH2 extends WP_Filesystem_Base {
} else {
$this->options['password'] = $opt['password'];
}
}
function connect() {
$this->debug("connect();");
if ( ! $this->keys ) {
$this->link = @ssh2_connect($this->options['hostname'], $this->options['port']);
$this->link = @ssh2_connect($this->options['hostname'], $this->options['port']);
} else {
$this->link = @ssh2_connect($this->options['hostname'], $this->options['port'], $this->options['hostkey']);
$this->link = @ssh2_connect($this->options['hostname'], $this->options['port'], $this->options['hostkey']);
}
if ( ! $this->link ) {
$this->errors->add('connect', sprintf(__('Failed to connect to SSH2 Server %1$s:%2$s'), $this->options['hostname'], $this->options['port']));
return false;
@@ -358,7 +358,7 @@ class WP_Filesystem_SSH2 extends WP_Filesystem_Base {
function touch($file, $time = 0, $atime = 0) {
//Not implmented.
}
function mkdir($path, $chmod = null, $chown = false, $chgrp = false) {
$this->debug("mkdir();");
$path = untrailingslashit($path);

View File

@@ -134,7 +134,7 @@ function _wp_dashboard_control_callback( $dashboard, $meta_box ) {
wp_dashboard_trigger_widget_control( $meta_box['id'] );
echo "<p class='submit'><input type='hidden' name='widget_id' value='$meta_box[id]' /><input type='submit' value='" . __( 'Submit' ) . "' /></p>";
echo '</form>';
echo '</form>';
}
/**
@@ -276,7 +276,7 @@ function wp_dashboard_right_now() {
} else {
printf(__ngettext('Theme <span class="b">%1$s</span> with <span class="b">%2$s Widget</span>', 'Theme <span class="b">%1$s</span> with <span class="b">%2$s Widgets</span>', $num_widgets), $ct->title, $num);
}
echo '</p>';
update_right_now_message();
@@ -304,7 +304,7 @@ function wp_dashboard_quick_press() {
'orderby' => 'modified',
'order' => 'DESC'
) );
if ( $drafts_query->posts )
$drafts =& $drafts_query->posts;
}
@@ -329,7 +329,7 @@ function wp_dashboard_quick_press() {
<div class="textarea-wrap">
<textarea name="content" id="content" class="mceEditor" rows="3" cols="15" tabindex="2"><?php echo $post->post_content; ?></textarea>
</div>
<script type="text/javascript">edCanvas = document.getElementById('content');edInsertContent = null;</script>
<h4><label for="tags-input"><?php _e('Tags') ?></label></h4>
@@ -437,7 +437,7 @@ function wp_dashboard_recent_comments() {
if ( current_user_can('edit_posts') ) { ?>
<p class="textright"><a href="edit-comments.php" class="button"><?php _e('View all'); ?></a></p>
<?php }
wp_comment_reply( -1, false, 'dashboard', false );
else :
@@ -785,7 +785,7 @@ function wp_dashboard_cached_rss_widget( $widget_id, $callback, $check_urls = ar
*/
function wp_dashboard_trigger_widget_control( $widget_control_id = false ) {
global $wp_dashboard_control_callbacks;
if ( is_scalar($widget_control_id) && $widget_control_id && isset($wp_dashboard_control_callbacks[$widget_control_id]) && is_callable($wp_dashboard_control_callbacks[$widget_control_id]) ) {
call_user_func( $wp_dashboard_control_callbacks[$widget_control_id], '', array( 'id' => $widget_control_id, 'callback' => $wp_dashboard_control_callbacks[$widget_control_id] ) );
}

View File

@@ -662,11 +662,11 @@ function request_filesystem_credentials($form_post, $type = '', $error = false)
$credentials['hostname'] = defined('FTP_HOST') ? FTP_HOST : (!empty($_POST['hostname']) ? $_POST['hostname'] : $credentials['hostname']);
$credentials['username'] = defined('FTP_USER') ? FTP_USER : (!empty($_POST['username']) ? $_POST['username'] : $credentials['username']);
$credentials['password'] = defined('FTP_PASS') ? FTP_PASS : (!empty($_POST['password']) ? $_POST['password'] : $credentials['password']);
// Check to see if we are setting the public/private keys for ssh
$credentials['public_key'] = defined('FTP_PUBKEY') ? FTP_PUBKEY : (!empty($_POST['public_key']) ? $_POST['public_key'] : $credentials['public_key']);
$credentials['private_key'] = defined('FTP_PRIKEY') ? FTP_PRIKEY : (!empty($_POST['private_key']) ? $_POST['private_key'] : $credentials['private_key']);
$credentials['private_key'] = defined('FTP_PRIKEY') ? FTP_PRIKEY : (!empty($_POST['private_key']) ? $_POST['private_key'] : $credentials['private_key']);
if ( strpos($credentials['hostname'], ':') )
list( $credentials['hostname'], $credentials['port'] ) = explode(':', $credentials['hostname'], 2);
@@ -704,7 +704,7 @@ jQuery(function($){
});
jQuery("#ftp, #ftps").click(function () {
jQuery("#ssh_keys").hide();
});
});
});
-->
</script>

View File

@@ -94,7 +94,7 @@ function wp_generate_attachment_metadata( $attachment_id, $file ) {
$metadata['height'] = $imagesize[1];
list($uwidth, $uheight) = wp_shrink_dimensions($metadata['width'], $metadata['height']);
$metadata['hwstring_small'] = "height='$uheight' width='$uwidth'";
// Make the file path relative to the upload dir
if ( ($uploads = wp_upload_dir()) && false === $uploads['error'] ) { // Get upload directory
if ( 0 === strpos($file, $uploads['basedir']) ) {// Check that the upload base exists in the file path

View File

@@ -102,7 +102,7 @@ function the_media_upload_tabs() {
function get_image_send_to_editor($id, $alt, $title, $align, $url='', $rel = false, $size='medium') {
$htmlalt = ( empty($alt) ) ? $title : $alt;
$html = get_image_tag($id, $htmlalt, $title, $align, $size);
$rel = $rel ? ' rel="attachment wp-att-'.attribute_escape($id).'"' : '';
@@ -473,7 +473,7 @@ function media_upload_image() {
$errors['upload_notice'] = __('Saved.');
return media_upload_gallery();
}
if ( isset($_GET['tab']) && $_GET['tab'] == 'type_url' )
return wp_iframe( 'media_upload_type_url_form', 'image', $errors, $id );
@@ -501,10 +501,10 @@ function media_sideload_image($file, $post_id, $desc = null) {
@unlink($file_array['tmp_name']);
$file_array['tmp_name'] = '';
}
$id = media_handle_sideload($file_array, $post_id, $desc);
$src = $id;
if ( is_wp_error($id) ) {
@unlink($file_array['tmp_name']);
return $id;
@@ -567,7 +567,7 @@ function media_upload_audio() {
if ( isset($_GET['tab']) && $_GET['tab'] == 'type_url' )
return wp_iframe( 'media_upload_type_url_form', 'audio', $errors, $id );
return wp_iframe( 'media_upload_type_form', 'audio', $errors, $id );
}
@@ -620,7 +620,7 @@ function media_upload_video() {
if ( isset($_GET['tab']) && $_GET['tab'] == 'type_url' )
return wp_iframe( 'media_upload_type_url_form', 'video', $errors, $id );
return wp_iframe( 'media_upload_type_form', 'video', $errors, $id );
}
@@ -673,7 +673,7 @@ function media_upload_file() {
if ( isset($_GET['tab']) && $_GET['tab'] == 'type_url' )
return wp_iframe( 'media_upload_type_url_form', 'file', $errors, $id );
return wp_iframe( 'media_upload_type_form', 'file', $errors, $id );
}
@@ -731,16 +731,16 @@ function media_upload_library() {
* @return unknown
*/
function image_align_input_fields($post, $checked='') {
$alignments = array('none' => 'None', 'left' => 'Left', 'center' => 'Center', 'right' => 'Right');
if ( !array_key_exists($checked, $alignments) )
$checked = 'none';
$out = array();
foreach ($alignments as $name => $label) {
$out[] = "<input type='radio' name='attachments[{$post->ID}][align]' id='image-align-{$name}-{$post->ID}' value='$name'".
( $checked == $name ? " checked='checked'" : "" ) .
( $checked == $name ? " checked='checked'" : "" ) .
" /><label for='image-align-{$name}-{$post->ID}' class='align image-align-{$name}-label'>" . __($label) . "</label>";
}
return join("\n", $out);
@@ -756,9 +756,9 @@ function image_align_input_fields($post, $checked='') {
* @return unknown
*/
function image_size_input_fields($post, $checked='') {
// get a list of the actual pixel dimensions of each possible intermediate version of this image
$size_names = array('thumbnail' => __('Thumbnail'), 'medium' => __('Medium'), 'large' => __('Large'), 'full' => __('Full size'));
$size_names = array('thumbnail' => __('Thumbnail'), 'medium' => __('Medium'), 'large' => __('Large'), 'full' => __('Full size'));
foreach ( $size_names as $size => $name) {
$downsize = image_downsize($post->ID, $size);
@@ -772,19 +772,19 @@ function image_size_input_fields($post, $checked='') {
// if $checked was not specified, default to the first available size that's bigger than a thumbnail
if ( !$checked && $enabled && 'thumbnail' != $size )
$checked = $size;
$html = "<div class='image-size-item'><input type='radio' ".( $enabled ? '' : "disabled='disabled'")."name='attachments[$post->ID][image-size]' id='{$css_id}' value='{$size}'".( $checked == $size ? " checked='checked'" : '') ." />";
$html .= "<label for='{$css_id}'>" . __($name). "</label>";
// only show the dimensions if that choice is available
if ( $enabled )
$html .= " <label for='{$css_id}' class='help'>" . sprintf( __("(%d&nbsp;&times;&nbsp;%d)"), $downsize[1], $downsize[2] ). "</label>";
$html .= '</div>';
$out[] = $html;
}
return array(
'label' => __('Size'),
'input' => 'html',
@@ -811,7 +811,7 @@ function image_link_input_fields($post, $url_type='') {
$url = $file;
elseif ( $url_type == 'post' )
$url = $link;
return "<input type='text' class='urlfield' name='attachments[$post->ID][url]' value='" . attribute_escape($url) . "' /><br />
<button type='button' class='button urlnone' title=''>" . __('None') . "</button>
<button type='button' class='button urlfile' title='" . attribute_escape($file) . "'>" . __('File URL') . "</button>
@@ -842,7 +842,7 @@ function image_attachment_fields_to_edit($form_fields, $post) {
'input' => 'html',
'html' => image_align_input_fields($post, get_option('image_default_align')),
);
$form_fields['image-size'] = image_size_input_fields($post, get_option('image_default_size'));
}
return $form_fields;
@@ -1287,7 +1287,7 @@ SWFUpload.onload = function() {
file_dialog_complete_handler : fileDialogComplete,
swfupload_pre_load_handler: swfuploadPreLoad,
swfupload_load_failed_handler: swfuploadLoadFailed,
custom_settings : {
custom_settings : {
degraded_element_id : "html-upload-ui", // id of the element displayed when swfupload is unavailable
swfupload_element_id : "flash-upload-ui" // id of the element displayed when swfupload is available
},
@@ -1299,7 +1299,7 @@ SWFUpload.onload = function() {
<div id="flash-upload-ui">
<?php do_action('pre-flash-upload-ui'); ?>
<div><?php _e( 'Choose files to upload' ); ?> <div id="flash-browse-button"></div></div>
<?php do_action('post-flash-upload-ui'); ?>
<p class="howto"><?php _e('After a file has been uploaded, you can add titles and descriptions.'); ?></p>
@@ -1361,7 +1361,7 @@ jQuery(function($){
-->
</script>
<div id="media-items">
<?php
<?php
if ( $id ) {
if ( !is_wp_error($id) ) {
echo get_media_items( $id, $errors );
@@ -1793,7 +1793,7 @@ function type_url_form_image() {
$default_align = get_option('image_default_align');
if ( empty($default_align) )
$default_align = 'none';
return '
<table class="describe"><tbody>
<tr>

View File

@@ -132,7 +132,7 @@ function install_dashboard() {
<?php _e('<strong>Tag:</strong> Searches for plugins tagged as such') ?><br />
<?php _e('<strong>Author:</strong> Searches for plugins created by the Author, or which the Author contributed to.') ?></p>
</div>
<h4><?php _e('Install a plugin in .zip format') ?></h4>
<p><?php _e('If you have a plugin in a .zip format, You may install it by uploading it here.') ?></p>
<form method="post" enctype="multipart/form-data" action="<?php echo admin_url('plugin-install.php?tab=upload') ?>">
@@ -140,7 +140,7 @@ function install_dashboard() {
<input type="file" name="pluginzip" />
<input type="submit" class="button" value="<?php _e('Install Now') ?>" />
</form>
<h4><?php _e('Popular tags') ?></h4>
<p><?php _e('You may also browse based on the most popular tags in the Plugin Directory:') ?></p>
<?php
@@ -396,7 +396,7 @@ function install_plugin_information() {
if( empty($section) || ! isset($api->sections[ $section ]) )
$section = array_shift( $section_titles = array_keys((array)$api->sections) );
iframe_header( __('Plugin Install') );
iframe_header( __('Plugin Install') );
echo "<div id='$tab-header'>\n";
echo "<ul id='sidemenu'>\n";
foreach ( (array)$api->sections as $section_name => $content ) {
@@ -505,9 +505,9 @@ function install_plugin_information() {
</div>
<div id="section-holder" class="wrap">
<?php
if ( version_compare($GLOBALS['wp_version'], $api->tested, '>') )
if ( version_compare($GLOBALS['wp_version'], $api->tested, '>') )
echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has <strong>not been tested</strong> with your current version of WordPress.') . '</p></div>';
else if ( version_compare($GLOBALS['wp_version'], $api->requires, '<') )
else if ( version_compare($GLOBALS['wp_version'], $api->requires, '<') )
echo '<div class="updated"><p>' . __('<strong>Warning:</strong> This plugin has not been marked as <strong>compatible</strong> with your version of WordPress.') . '</p></div>';
foreach ( (array)$api->sections as $section_name => $content ) {
$title = $section_name;
@@ -549,11 +549,11 @@ function upload_plugin() {
echo '<div class="wrap">';
echo '<h2>', sprintf( __('Installing Plugin from file: %s'), basename($filename) ), '</h2>';
//Handle a newly uploaded file, Else assume it was
//Handle a newly uploaded file, Else assume it was
if ( !empty($_FILES) ) {
$filename = wp_unique_filename( $uploads['basedir'], $filename );
$local_file = $uploads['basedir'] . '/' . $filename;
// Move the file to the uploads dir
if ( false === @ move_uploaded_file( $_FILES['pluginzip']['tmp_name'], $local_file) )
wp_die( sprintf( __('The uploaded file could not be moved to %s.' ), $uploads['path']));
@@ -578,7 +578,7 @@ function install_plugin() {
check_admin_referer('install-plugin_' . $plugin);
$api = plugins_api('plugin_information', array('slug' => $plugin, 'fields' => array('sections' => false) ) ); //Save on a bit of bandwidth.
if ( is_wp_error($api) )
wp_die($api);
@@ -660,7 +660,7 @@ function do_plugin_install_local_package($package, $filename = '') {
show_message( __('No plugin Specified') );
return;
}
if ( empty($filename) )
$filename = basename($package);

View File

@@ -553,7 +553,7 @@ function add_menu_page( $page_title, $menu_title, $access_level, $file, $functio
if ( empty($icon_url) )
$icon_url = 'images/generic.png';
$menu[] = array ( $menu_title, $access_level, $file, $page_title, 'menu-top ' . $hookname, $hookname, $icon_url );
return $hookname;
@@ -641,7 +641,7 @@ function add_submenu_page( $parent, $page_title, $menu_title, $access_level, $fi
/**
* Add sub menu page to the tools main menu.
*
* @param string $page_title
* @param string $page_title
* @param unknown_type $menu_title
* @param unknown_type $access_level
* @param unknown_type $file

View File

@@ -1044,13 +1044,13 @@ function wp_create_post_autosave( $post_id ) {
*
* @package WordPress
* @since 2.7
*
*
* @uses wp_write_post()
* @uses edit_post()
* @uses get_post()
* @uses current_user_can()
* @uses wp_create_post_autosave()
*
*
* @return str URL to redirect to show the preview
*/
function post_preview() {
@@ -1058,13 +1058,13 @@ function post_preview() {
$post_ID = (int) $_POST['post_ID'];
if ( $post_ID < 1 )
wp_die( __('Preview not available. Please save as a draft first.') );
if ( isset($_POST['catslist']) )
$_POST['post_category'] = explode(",", $_POST['catslist']);
if ( isset($_POST['tags_input']) )
$_POST['tags_input'] = explode(",", $_POST['tags_input']);
if ( $_POST['post_type'] == 'page' || empty($_POST['post_category']) )
unset($_POST['post_category']);
@@ -1102,7 +1102,7 @@ function post_preview() {
/**
* Adds the TinyMCE editor used on the Write and Edit screens.
*
*
* Has option to output a trimmed down version used in Press This.
*
* @package WordPress

View File

@@ -301,7 +301,7 @@ function populate_options() {
add_option('widget_rss', array());
add_option('update_core', array());
add_option('dismissed_update_core', array());
// Delete unused options
$unusedoptions = array ('blodotgsping_url', 'bodyterminator', 'emailtestonly', 'phoneemail_separator', 'smilies_directory', 'subjectprefix', 'use_bbcode', 'use_blodotgsping', 'use_phoneemail', 'use_quicktags', 'use_weblogsping', 'weblogs_cache_file', 'use_preview', 'use_htmltrans', 'smilies_directory', 'fileupload_allowedusers', 'use_phoneemail', 'default_post_status', 'default_post_category', 'archive_mode', 'time_difference', 'links_minadminlevel', 'links_use_adminlevels', 'links_rating_type', 'links_rating_char', 'links_rating_ignore_zero', 'links_rating_single_image', 'links_rating_image0', 'links_rating_image1', 'links_rating_image2', 'links_rating_image3', 'links_rating_image4', 'links_rating_image5', 'links_rating_image6', 'links_rating_image7', 'links_rating_image8', 'links_rating_image9', 'weblogs_cacheminutes', 'comment_allowed_tags', 'search_engine_friendly_urls', 'default_geourl_lat', 'default_geourl_lon', 'use_default_geourl', 'weblogs_xml_url', 'new_users_can_blog', '_wpnonce', '_wp_http_referer', 'Update', 'action', 'rich_editing', 'autosave_interval', 'deactivated_plugins');
foreach ($unusedoptions as $option) :

View File

@@ -911,7 +911,7 @@ function register_column_headers($screen, $columns) {
*/
function get_hidden_columns($page) {
$page = str_replace('.php', '', $page);
return (array) get_user_option( 'manage-' . $page . '-columns-hidden', 0, false );
return (array) get_user_option( 'manage-' . $page . '-columns-hidden', 0, false );
}
/**
@@ -1000,7 +1000,7 @@ function inline_edit_row( $type ) {
</label>
<?php
endif; // authors
endif; // authors
$authors_dropdown = ob_get_clean();
?>
@@ -1335,7 +1335,7 @@ function _post_row($a_post, $pending_comments, $mode) {
$m_time = $post->post_date;
$time = get_post_time('G', true, $post);
$time_diff = time() - $time;
$time_diff = time() - $time;
if ( ( 'future' == $post->post_status) ) {
if ( $time_diff <= 0 ) {
@@ -2316,7 +2316,7 @@ function _list_meta_row( $entry, &$count ) {
$r .= "\n\t\t<input name='updatemeta' type='submit' tabindex='6' value='".attribute_escape(__( 'Update' ))."' class='add:the-list:meta-{$entry['meta_id']}::_ajax_nonce=$update_nonce updatemeta' /></div>";
$r .= wp_nonce_field( 'change-meta', '_ajax_nonce', false, false );
$r .= "</td>";
$r .= "\n\t\t<td><label class='hidden' for='meta[{$entry['meta_id']}][value]'>" . __( 'Value' ) . "</label><textarea name='meta[{$entry['meta_id']}][value]' id='meta[{$entry['meta_id']}][value]' tabindex='6' rows='2' cols='30'>{$entry['meta_value']}</textarea></td>\n\t</tr>";
return $r;
}
@@ -2375,7 +2375,7 @@ function meta_form() {
<tr><td colspan="2" class="submit">
<input type="submit" id="addmetasub" name="addmeta" class="add:the-list:newmeta" tabindex="9" value="<?php _e( 'Add Custom Field' ) ?>" />
<?php wp_nonce_field( 'add-meta', '_ajax_nonce', false ); ?>
<?php wp_nonce_field( 'add-meta', '_ajax_nonce', false ); ?>
</td></tr>
</tbody>
</table>
@@ -3038,7 +3038,7 @@ function find_posts_div($found_action = '') {
</div>
</div>
<script type="text/javascript">
/* <![CDATA[ */
/* <![CDATA[ */
(function($){
findPosts = {
open : function(af_name, af_val) {
@@ -3133,7 +3133,7 @@ function find_posts_div($found_action = '') {
});
});
})(jQuery);
/* ]]> */
/* ]]> */
</script>
<?php
}
@@ -3160,7 +3160,7 @@ function the_post_password() {
function favorite_actions() {
$actions = array(
'post-new.php' => array(__('New Post'), 'edit_posts'),
'edit.php?post_status=draft' => array(__('Drafts'), 'edit_posts'),
'edit.php?post_status=draft' => array(__('Drafts'), 'edit_posts'),
'page-new.php' => array(__('New Page'), 'edit_pages'),
'media-new.php' => array(__('Upload'), 'upload_files'),
'edit-comments.php' => array(__('Comments'), 'moderate_comments')
@@ -3325,10 +3325,10 @@ function screen_meta($screen) {
<h5><?php _e('Show on screen') ?></h5>
<form id="adv-settings" action="" method="get">
<div class="metabox-prefs">
<?php
<?php
if ( !meta_box_prefs($screen) && isset($column_screens) ) {
manage_columns_prefs($screen);
wp_nonce_field( 'hiddencolumns', 'hiddencolumnsnonce', false );
wp_nonce_field( 'hiddencolumns', 'hiddencolumnsnonce', false );
}
?>
<br class="clear" />
@@ -3367,7 +3367,7 @@ function screen_meta($screen) {
if ( !isset($_wp_contextual_help['options-general']) )
$_wp_contextual_help['options-general'] = __('<a href="http://codex.wordpress.org/Settings_General_SubPanel" target="_blank">General Settings</a>');
$_wp_contextual_help = apply_filters('contextual_help_list', $_wp_contextual_help, $screen);
$_wp_contextual_help = apply_filters('contextual_help_list', $_wp_contextual_help, $screen);
?>
<div id="contextual-help-wrap" class="hidden">
<?php

View File

@@ -292,7 +292,7 @@ function wp_update_theme($theme, $feedback = '') {
return new WP_Error('up_to_date', __('The theme is at the latest version.'));
$r = $current->response[ $theme ];
$themes = get_themes();
foreach ( (array) $themes as $this_theme ) {
if ( $this_theme['Stylesheet'] == $theme ) {
@@ -457,12 +457,12 @@ function wp_update_core($current, $feedback = '') {
$result = unzip_file($download_file, $working_dir);
// Once extracted, delete the package
unlink($download_file);
if ( is_wp_error($result) ) {
$wp_filesystem->delete($working_dir, true);
return $result;
}
// Copy update-core.php from the new version into place.
if ( !$wp_filesystem->copy($working_dir . '/wordpress/wp-admin/includes/update-core.php', $wp_dir . 'wp-admin/includes/update-core.php', true) ) {
$wp_filesystem->delete($working_dir, true);

View File

@@ -2,7 +2,7 @@
/**
* WordPress Upgrade API
*
* Most of the functions are pluggable and can be overwritten
* Most of the functions are pluggable and can be overwritten
*
* @package WordPress
* @subpackage Administration

View File

@@ -98,8 +98,8 @@ function edit_user( $user_id = 0 ) {
else
$user->rich_editing = 'true';
$user->comment_shortcuts = isset( $_POST['comment_shortcuts'] )? $_POST['comment_shortcuts'] : '';
$user->comment_shortcuts = isset( $_POST['comment_shortcuts'] )? $_POST['comment_shortcuts'] : '';
$user->use_ssl = 0;
if ( !empty($_POST['use_ssl']) )
$user->use_ssl = 1;

View File

@@ -17,7 +17,7 @@
* check_column('wp_links', 'link_description', 'mediumtext');
* if (check_column($wpdb->comments, 'comment_author', 'tinytext'))
* echo "ok\n";
*
*
* $error_count = 0;
* $tablename = $wpdb->links;
* // check the column
@@ -25,7 +25,7 @@
* $ddl = "ALTER TABLE $wpdb->links MODIFY COLUMN link_description varchar(255) NOT NULL DEFAULT '' ";
* $q = $wpdb->query($ddl);
* }
*
*
* if (check_column($wpdb->links, 'link_description', 'varchar(255)')) {
* $res .= $tablename . ' - ok <br />';
* } else {

View File

@@ -7,7 +7,7 @@ jQuery(function($) {
var name = $("<span>" + $('name', r).text() + "</span>").html();
var id = $('cat', r).attr('id');
options[options.length] = new Option(name, id);
addAfter2( r, settings );
}

View File

@@ -142,7 +142,7 @@ jQuery(document).ready( function($) {
$('form.validate').submit( function() { return wpAjax.validateForm( $(this) ); } );
}
// Move .updated and .error alert boxes
// Move .updated and .error alert boxes
$('div.wrap h2 ~ div.updated, div.wrap h2 ~ div.error').addClass('below-h2');
$('div.updated, div.error').not('.below-h2').insertAfter('div.wrap h2:first');
@@ -156,7 +156,7 @@ jQuery(document).ready( function($) {
$('#show-settings-link').css({'backgroundImage':'url("images/screen-options-right.gif")'});
$('#contextual-help-link-wrap').removeClass('invisible');
$(this).removeClass('screen-options-open');
} else {
$('#show-settings-link').css({'backgroundImage':'url("images/screen-options-right-up.gif")'});
$(this).addClass('screen-options-open');
@@ -164,7 +164,7 @@ jQuery(document).ready( function($) {
});
return false;
});
// help tab
$('#contextual-help-link').click(function () {
if ( ! $('#contextual-help-wrap').hasClass('contextual-help-open') ) {
@@ -239,7 +239,7 @@ showNotice = {
return false;
},
note : function(text) {
alert(text);
}
@@ -248,10 +248,10 @@ showNotice = {
(function($){
// sidebar admin menu
adminMenu = {
init : function() {
$('#adminmenu div.wp-menu-toggle').each( function() {
if ( $(this).siblings('.wp-submenu').length )
if ( $(this).siblings('.wp-submenu').length )
$(this).click(function(){ adminMenu.toggle( $(this).siblings('.wp-submenu') ); });
else
$(this).hide();
@@ -282,7 +282,7 @@ adminMenu = {
if ( $(e).hasClass('wp-has-current-submenu') ) return true; // leave the current parent open
if ( 'o' == v ) $(e).addClass('wp-menu-open');
else if ( 'c' == v ) $(e).removeClass('wp-menu-open');
else if ( 'c' == v ) $(e).removeClass('wp-menu-open');
});
},
@@ -297,7 +297,7 @@ adminMenu = {
return false;
},
fold : function(off) {
if (off) {
$('#wpcontent').removeClass('folded');
@@ -321,14 +321,14 @@ adminMenu = {
sensitivity: 8,
interval: 100
});
}
},
favorites : function() {
$('#favorite-inside').width($('#favorite-actions').width()-4);
$('#favorite-toggle, #favorite-inside').bind( 'mouseenter', function(){$('#favorite-inside').removeClass('slideUp').addClass('slideDown'); setTimeout(function(){if ( $('#favorite-inside').hasClass('slideDown') ) { $('#favorite-inside').slideDown(100); $('#favorite-first').addClass('slide-down'); }}, 200) } );
$('#favorite-toggle, #favorite-inside').bind( 'mouseleave', function(){$('#favorite-inside').removeClass('slideDown').addClass('slideUp'); setTimeout(function(){if ( $('#favorite-inside').hasClass('slideUp') ) { $('#favorite-inside').slideUp(100, function(){ $('#favorite-first').removeClass('slide-down'); } ); }}, 300) } );
}
};
@@ -368,7 +368,7 @@ columns = {
jQuery(document).ready(function($){
if ( 'undefined' != typeof google && google.gears ) return;
var gf = false;
if ( 'undefined' != typeof GearsFactory ) {
gf = new GearsFactory();
@@ -390,6 +390,6 @@ jQuery(document).ready(function($){
}
if ( gf && gf.hasPermission )
return;
$('.turbo-nag').show();
});

View File

@@ -4,7 +4,7 @@ var theList; var theExtraList;
setCommentsList = function() {
var dimAfter = function( r, settings ) {
var c = $('#' + settings.element);
if ( c.is('.unapproved') )
c.find('div.comment_status').html('0')
else

View File

@@ -21,7 +21,7 @@ switchEditors = {
tinyMCE.execCommand("mceAddControl", false, "content");
}
},
saveCallback : function(el, content, body) {
if ( tinyMCE.activeEditor.isHidden() )

View File

@@ -25,7 +25,7 @@ jQuery._farbtastic = function (container, callback) {
fb.radius = 84;
fb.square = 100;
fb.width = 194;
// Fix background PNGs in IE6
if (navigator.appVersion.match(/MSIE [0-6]\./)) {
jQuery('*', e).each(function () {

View File

@@ -49,10 +49,10 @@ inlineEditTax = {
var editRow = $('#inline-edit').clone(true), rowData = $('#inline_'+id);
$('td', editRow).attr('colspan', $('.widefat:first thead th:visible').length);
if ( $(t.what+id).hasClass('alternate') )
$(editRow).addClass('alternate');
$(t.what+id).hide().after(editRow);
$(':input[name="name"]', editRow).val( $('.name', rowData).text() );
@@ -105,7 +105,7 @@ inlineEditTax = {
// make ajax request
$.post('admin-ajax.php', params,
function(r) {
$('table.widefat .inline-edit-save .waiting').hide();
if (r) {
@@ -115,7 +115,7 @@ inlineEditTax = {
var row = $(inlineEditTax.what+id);
row.hide();
row.find('.hide-if-no-js').removeClass('hide-if-no-js');
inlineEditTax.addEvents(row);
row.fadeIn();

View File

@@ -12,9 +12,9 @@ function passwordStrength(password,username) {
var symbolSize = 0;
if (password.match(/[0-9]/)) symbolSize +=10;
if (password.match(/[a-z]/)) symbolSize +=26;
if (password.match(/[A-Z]/)) symbolSize +=26;
if (password.match(/[A-Z]/)) symbolSize +=26;
if (password.match(/[^a-zA-Z0-9]/)) symbolSize +=31;
var natLog = Math.log( Math.pow(symbolSize,password.length) );
var score = natLog / Math.LN2;
if (score < 40 ) return badPass

View File

@@ -97,7 +97,7 @@ function tag_press_key( e ) {
jQuery(document).ready( function($) {
tagCloud.init();
// close postboxes that should be closed
jQuery('.if-js-closed').removeClass('if-js-closed').addClass('closed');
@@ -450,6 +450,6 @@ jQuery(document).ready( function($) {
return false;
}
};
})(jQuery);

View File

@@ -15,7 +15,7 @@ wpGears = {
getPermission : function() {
var perm = true;
if ( 'undefined' != typeof google && google.gears ) {
if ( ! google.gears.factory.hasPermission )
perm = google.gears.factory.getPermission( 'WordPress', 'images/logo.gif' );

View File

@@ -41,7 +41,7 @@ if ( isset($_GET['inline']) ) {
wp_redirect( admin_url($location) );
}
if ( isset($_POST['html-upload']) && !empty($_FILES) ) {
// Upload File button was clicked
$id = media_handle_upload('async-upload', $_REQUEST['post_id']);
@@ -57,7 +57,7 @@ if ( isset($_GET['inline']) ) {
require_once('admin-header.php'); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form enctype="multipart/form-data" method="post" action="media-upload.php?inline=&amp;upload-page-form=" class="media-upload-form type-form validate" id="file-form">
@@ -93,15 +93,15 @@ if ( isset($_GET['inline']) ) {
$type = strval($_GET['type']);
else
$type = apply_filters('media_upload_default_type', 'file');
// tab: gallery, library, or type-specific
if ( isset($_GET['tab']) )
$tab = strval($_GET['tab']);
else
$tab = apply_filters('media_upload_default_tab', 'type');
$body_id = 'media-upload';
// let the action code decide how to handle the request
if ( $tab == 'type' || $tab == 'type_url' )
do_action("media_upload_$type");

View File

@@ -15,7 +15,7 @@
* 2: The URL of the item's file
* 3: Class
* 4: ID
* 5: Icon for top level menu
* 5: Icon for top level menu
*
* @global array $menu
* @name $menu
@@ -65,7 +65,7 @@ if ( !empty($update_plugins->response) )
$menu[45] = array( sprintf( __('Plugins %s'), "<span class='update-plugins count-$update_count'><span class='plugin-count'>" . number_format_i18n($update_count) . "</span></span>" ), 'activate_plugins', 'plugins.php', '', 'menu-top', 'menu-plugins', 'div' );
$submenu['plugins.php'][5] = array( __('Installed'), 'activate_plugins', 'plugins.php' );
$submenu['plugins.php'][10] = array(_c('Add New|plugin'), 'install_plugins', 'plugin-install.php');
$submenu['plugins.php'][10] = array(_c('Add New|plugin'), 'install_plugins', 'plugin-install.php');
$submenu['plugins.php'][15] = array( __('Editor'), 'edit_plugins', 'plugin-editor.php' );
if ( current_user_can('edit_users') )
@@ -104,7 +104,7 @@ $_wp_last_utility_menu = 60; // The index of the last top-level menu in the util
$menu[79] = array( '', 'read', '', '', 'wp-menu-separator-last' );
// Back-compat for old top-levels
$_wp_real_parent_file['post.php'] = 'edit.php';
$_wp_real_parent_file['post.php'] = 'edit.php';
$_wp_real_parent_file['post-new.php'] = 'edit.php';
$_wp_real_parent_file['page-new.php'] = 'edit-pages.php';

View File

@@ -17,7 +17,7 @@ include('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">
<?php settings_fields('discussion'); ?>
@@ -58,7 +58,7 @@ include('admin-header.php');
<br />
<label for="thread_comments">
<input name="thread_comments" type="checkbox" id="thread_comments" value="1" <?php checked('1', get_option('thread_comments')); ?> />
<?php
<?php
$maxdeep = (int) apply_filters( 'thread_comments_depth_max', 10 );

View File

@@ -50,7 +50,7 @@ include('./admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">
<?php settings_fields('general'); ?>

View File

@@ -18,7 +18,7 @@ include('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form action="options.php" method="post">
<?php settings_fields('media'); ?>
@@ -49,15 +49,15 @@ include('admin-header.php');
</fieldset></td>
</tr>
<tr valign="top">
<th scope="row"><?php _e('Large size') ?></th>
<td><fieldset><legend class="hidden"><?php _e('Large size') ?></legend>
<label for="large_size_w"><?php _e('Max Width'); ?></label>
<input name="large_size_w" type="text" id="large_size_w" value="<?php form_option('large_size_w'); ?>" class="small-text" />
<label for="large_size_h"><?php _e('Max Height'); ?></label>
<input name="large_size_h" type="text" id="large_size_h" value="<?php form_option('large_size_h'); ?>" class="small-text" />
</fieldset></td>
</tr>
<tr valign="top">
<th scope="row"><?php _e('Large size') ?></th>
<td><fieldset><legend class="hidden"><?php _e('Large size') ?></legend>
<label for="large_size_w"><?php _e('Max Width'); ?></label>
<input name="large_size_w" type="text" id="large_size_w" value="<?php form_option('large_size_w'); ?>" class="small-text" />
<label for="large_size_h"><?php _e('Max Height'); ?></label>
<input name="large_size_h" type="text" id="large_size_h" value="<?php form_option('large_size_h'); ?>" class="small-text" />
</fieldset></td>
</tr>
<?php do_settings_fields('media', 'default'); ?>
</table>

View File

@@ -18,7 +18,7 @@ include('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">
<?php settings_fields('misc'); ?>

View File

@@ -124,7 +124,7 @@ else
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form name="form" action="options-permalink.php" method="post">
<?php wp_nonce_field('update-permalink') ?>

View File

@@ -17,7 +17,7 @@ include('./admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">
<?php settings_fields('privacy'); ?>

View File

@@ -17,7 +17,7 @@ include('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form name="form1" method="post" action="options.php">
<?php settings_fields('reading'); ?>

View File

@@ -17,7 +17,7 @@ include('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">
<?php settings_fields('writing'); ?>

View File

@@ -31,7 +31,7 @@ $whitelist_options = array(
'writing' => array( 'default_post_edit_rows', 'use_smilies', 'ping_sites', 'mailserver_url', 'mailserver_port', 'mailserver_login', 'mailserver_pass', 'default_category', 'default_email_category', 'use_balanceTags', 'default_link_category', 'enable_app', 'enable_xmlrpc' ),
'options' => array( '' ) );
if ( !defined( 'WP_SITEURL' ) ) $whitelist_options['general'][] = 'siteurl';
if ( !defined( 'WP_HOME' ) ) $whitelist_options['general'][] = 'home';
if ( !defined( 'WP_HOME' ) ) $whitelist_options['general'][] = 'home';
$whitelist_options = apply_filters( 'whitelist_options', $whitelist_options );

View File

@@ -97,7 +97,7 @@ default:
<?php endif; ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<div class="tablenav">
<div class="alignleft">

View File

@@ -53,7 +53,7 @@ include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<ul class="subsubsub">
<?php

View File

@@ -202,7 +202,7 @@ if ( !empty($invalid) )
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<p><?php _e('Plugins extend and expand the functionality of WordPress. Once a plugin is installed, you may activate it or deactivate it here.'); ?></p>
<?php
@@ -257,7 +257,7 @@ function print_plugins_table($plugins, $context = '') {
<th scope="col" class="action-links"><?php _e('Action'); ?></th>
</tr>
</thead>
<tfoot>
<tr>
<th scope="col" class="check-column"><input type="checkbox" /></th>
@@ -267,7 +267,7 @@ function print_plugins_table($plugins, $context = '') {
<th scope="col" class="action-links"><?php _e('Action'); ?></th>
</tr>
</tfoot>
<tbody class="plugins">
<?php
@@ -334,7 +334,7 @@ function print_plugin_actions($context) {
<?php if( 'recent' == $context ) : ?>
<input type="submit" name="clear-recent-list" value="<?php _e('Clear List') ?>" class="button-secondary" />
<?php endif; ?>
</div>
</div>
<?php
}
?>

View File

@@ -100,7 +100,7 @@ $desc_header = ( $description != $file_show ) ? "$description</strong> (%s)" : "
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<div class="bordertitle">
<form id="themeselector" action="theme-editor.php" method="post">
<strong><label for="theme"><?php _e('Select theme to edit:'); ?> </label></strong>
@@ -141,11 +141,11 @@ if ($allowed_files) :
$template_show = basename($template_file);
$filedesc = ( $description != $template_file ) ? "$description <span class='nonessential'>($template_show)</span>" : "$description";
$filedesc = ( $template_file == $file ) ? "<span class='highlight'>$description <span class='nonessential'>($template_show)</span></span>" : $filedesc;
// If we have two files of the same name prefer the one in the Template Directory
// This means that we display the correct files for child themes which overload Templates as well as Styles
if( array_key_exists($description, $template_mapping ) ) {
if ( false !== strpos( $template_file, $template_dir ) ) {
if ( false !== strpos( $template_file, $template_dir ) ) {
$template_mapping[ $description ] = array( $template_file, $filedesc );
}
} else {

View File

@@ -101,7 +101,7 @@ function theme_update_available( $theme ) {
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h3><?php _e('Current Theme'); ?></h3>
<div id="current-theme">

View File

@@ -81,7 +81,7 @@ if ( ! $is_opera ) {
<div class="tool-box">
<h3 class="title"><?php _e('Press This') ?></h3>
<p><?php _e('Press This is a bookmarklet: a little app that runs in your browser and lets you grab bits of the web.');?></p>
<p><?php _e('Use Press This to clip text, images and videos from any web page. Then edit and add more straight from Press This before you save or publish it in a post on your blog.'); ?></p>
<p><?php _e('Drag-and-drop the following link to your bookmarks bar or right click it and add it to your favorites for a posting shortcut.') ?></p>
<p class="pressthis"><a href="<?php echo htmlspecialchars( get_shortcut_link() ); ?>" title="<?php echo attribute_escape(__('Press This')) ?>"><?php _e('Press This') ?></a></p>

View File

@@ -49,18 +49,18 @@ function list_core_update( $update ) {
echo '<input id="undismiss" class="button" type="submit" value="' . attribute_escape(__('Bring back this update')) . '" name="undismiss" />';
echo '</p>';
echo '</form>';
}
function dismissed_updates() {
$dismissed = get_core_updates( array( 'dismissed' => true, 'available' => false ) );
if ( $dismissed ) {
$show_text = js_escape(__('Show hidden updates'));
$hide_text = js_escape(__('Hide hidden updates'));
?>
<script type="text/javascript">
jQuery(function($) {
$('dismissed-updates').show();
$('#show-dismissed').toggle(function(){$(this).text('<?php echo $hide_text; ?>');}, function() {$(this).text('<?php echo $show_text; ?>')});
@@ -76,7 +76,7 @@ function dismissed_updates() {
echo '</li>';
}
echo '</ul>';
}
}
}
/**
@@ -99,9 +99,9 @@ function core_upgrade_preamble() {
echo '</h3>';
} else {
echo '<div class="updated fade"><p>';
_e('<strong>Important:</strong> before upgrading, please <a href="http://codex.wordpress.org/WordPress_Backups">backup your database and files</a>.');
_e('<strong>Important:</strong> before upgrading, please <a href="http://codex.wordpress.org/WordPress_Backups">backup your database and files</a>.');
echo '</p></div>';
echo '<h3 class="response">';
_e( 'There is a new version of WordPress available for upgrade' );
echo '</h3>';
@@ -131,17 +131,17 @@ function core_upgrade_preamble() {
*/
function do_core_upgrade() {
global $wp_filesystem;
$url = wp_nonce_url('update-core.php?action=do-core-upgrade', 'upgrade-core');
if ( false === ($credentials = request_filesystem_credentials($url)) )
return;
$version = isset( $_POST['version'] )? $_POST['version'] : false;
$locale = isset( $_POST['locale'] )? $_POST['locale'] : 'en_US';
$update = find_core_update( $version, $locale );
if ( !$update )
return;
if ( ! WP_Filesystem($credentials) ) {
request_filesystem_credentials($url, '', true); //Failed to connect, Error and request again
@@ -192,7 +192,7 @@ function do_undismiss_core_update() {
}
$action = isset($_GET['action']) ? $_GET['action'] : 'upgrade-core';
if ( 'upgrade-core' == $action ) {
$title = __('Upgrade WordPress');
$parent_file = 'tools.php';

View File

@@ -126,7 +126,7 @@ if ( isset($_GET['action']) ) {
$plugin = isset($_GET['plugin']) ? trim($_GET['plugin']) : '';
$theme = isset($_REQUEST['theme']) ? urldecode($_REQUEST['theme']) : '';
$action = isset($_GET['action']) ? $_GET['action'] : '';
if ( 'upgrade-plugin' == $action ) {
check_admin_referer('upgrade-plugin_' . $plugin);
$title = __('Upgrade Plugin');
@@ -153,7 +153,7 @@ if ( isset($_GET['action']) ) {
include(WP_PLUGIN_DIR . '/' . $plugin);
}
iframe_footer();
} elseif ( 'upgrade-theme' == $action ) {
} elseif ( 'upgrade-theme' == $action ) {
check_admin_referer('upgrade-theme_' . $theme);
$title = __('Upgrade Theme');
$parent_file = 'themes.php';

View File

@@ -62,7 +62,7 @@ if ( isset($_GET['find_detached'] ) ) {
if ( false !== strpos($referer, 'upload.php') )
$location = $referer;
}
$location = add_query_arg( array( 'detached' => 1, 'attached' => $attached ) , $location );
wp_redirect($location);
exit;
@@ -172,7 +172,7 @@ if ( isset($_GET['s']) && $_GET['s'] )
<?php
if ( isset($message) ) { ?>
<div id="message" class="updated fade"><p><?php echo $message; ?></p></div>
<?php
<?php
}
?>

View File

@@ -23,7 +23,7 @@ function profile_js ( ) {
?>
<script type="text/javascript">
(function($){
function check_pass_strength () {
var pass = $('#pass1').val();
@@ -177,7 +177,7 @@ include ('admin-header.php');
<div class="wrap" id="profile-page">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form id="your-profile" action="" method="post">
<?php wp_nonce_field('update-user_' . $user_id) ?>

View File

@@ -235,7 +235,7 @@ require_once( 'admin-header.php' ); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form id="widgets-filter" action="" method="get">

View File

@@ -816,7 +816,7 @@ div.comment-item:hover .row-actions {
#adminmenu .wp-submenu li.current a:hover {
font-weight: bold;
}
#adminmenu a.menu-top,
#adminmenu .wp-submenu-head {
font: normal 13px/18px Georgia, "Times New Roman", "Bitstream Charter", Times, serif;
@@ -962,9 +962,9 @@ div.comment-item:hover .row-actions {
cursor: w-resize;
}
.folded #adminmenu li.wp-menu-separator {
cursor: e-resize;
}
.folded #adminmenu li.wp-menu-separator {
cursor: e-resize;
}
#adminmenu .wp-menu-separator-last {
height: 10px;
@@ -1604,7 +1604,7 @@ table.form-table td .updated {
#poststuff #titlewrap {
border: 0;
padding: 0;
}
#titlediv #title {
@@ -2059,7 +2059,7 @@ fieldset {
height: 20px;
line-height: 20px;
padding: 0;
}
}
#jj, #hh, #mn {
width: 2em;