mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-27 10:08:27 +00:00
Remove remains from the old bookmarklet code
git-svn-id: http://svn.automattic.com/wordpress/trunk@12029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
0a665944e8
commit
c790ebcdd9
@ -48,7 +48,7 @@ $posts_per_page = get_option('posts_per_page');
|
|||||||
$date_format = get_option('date_format');
|
$date_format = get_option('date_format');
|
||||||
$time_format = get_option('time_format');
|
$time_format = get_option('time_format');
|
||||||
|
|
||||||
wp_reset_vars(array('profile', 'redirect', 'redirect_url', 'a', 'popuptitle', 'popupurl', 'text', 'trackback', 'pingback'));
|
wp_reset_vars(array('profile', 'redirect', 'redirect_url', 'a', 'text', 'trackback', 'pingback'));
|
||||||
|
|
||||||
wp_admin_css_color('classic', __('Blue'), admin_url("css/colors-classic.css"), array('#073447', '#21759B', '#EAF3FA', '#BBD8E7'));
|
wp_admin_css_color('classic', __('Blue'), admin_url("css/colors-classic.css"), array('#073447', '#21759B', '#EAF3FA', '#BBD8E7'));
|
||||||
wp_admin_css_color('fresh', __('Gray'), admin_url("css/colors-fresh.css"), array('#464646', '#6D6D6D', '#F1F1F1', '#DFDFDF'));
|
wp_admin_css_color('fresh', __('Gray'), admin_url("css/colors-fresh.css"), array('#464646', '#6D6D6D', '#F1F1F1', '#DFDFDF'));
|
||||||
|
@ -128,10 +128,6 @@ require_once('admin-header.php');
|
|||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<?php if ( (isset($mode) && 'bookmarklet' == $mode) || isset($_GET['popupurl']) ): ?>
|
|
||||||
<input type="hidden" name="mode" value="bookmarklet" />
|
|
||||||
<?php endif; ?>
|
|
||||||
|
|
||||||
<div class="wrap">
|
<div class="wrap">
|
||||||
<?php screen_icon(); ?>
|
<?php screen_icon(); ?>
|
||||||
<h2><?php echo esc_html( $title ); ?></h2>
|
<h2><?php echo esc_html( $title ); ?></h2>
|
||||||
|
@ -109,12 +109,8 @@ require_once('admin-header.php');
|
|||||||
<div id="message" class="updated fade"><p><?php echo $message; ?></p></div>
|
<div id="message" class="updated fade"><p><?php echo $message; ?></p></div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php
|
<?php wp_nonce_field($nonce_action); ?>
|
||||||
wp_nonce_field($nonce_action);
|
|
||||||
|
|
||||||
if (isset($mode) && 'bookmarklet' == $mode)
|
|
||||||
echo '<input type="hidden" name="mode" value="bookmarklet" />';
|
|
||||||
?>
|
|
||||||
<input type="hidden" id="user-id" name="user_ID" value="<?php echo $user_ID ?>" />
|
<input type="hidden" id="user-id" name="user_ID" value="<?php echo $user_ID ?>" />
|
||||||
<input type="hidden" id="hiddenaction" name="action" value='<?php echo esc_attr($form_action) ?>' />
|
<input type="hidden" id="hiddenaction" name="action" value='<?php echo esc_attr($form_action) ?>' />
|
||||||
<input type="hidden" id="originalaction" name="originalaction" value="<?php echo esc_attr($form_action) ?>" />
|
<input type="hidden" id="originalaction" name="originalaction" value="<?php echo esc_attr($form_action) ?>" />
|
||||||
|
@ -326,29 +326,18 @@ function bulk_edit_posts( $post_data = null ) {
|
|||||||
* @return unknown
|
* @return unknown
|
||||||
*/
|
*/
|
||||||
function get_default_post_to_edit() {
|
function get_default_post_to_edit() {
|
||||||
|
|
||||||
|
$post_title = '';
|
||||||
if ( !empty( $_REQUEST['post_title'] ) )
|
if ( !empty( $_REQUEST['post_title'] ) )
|
||||||
$post_title = esc_html( stripslashes( $_REQUEST['post_title'] ));
|
$post_title = esc_html( stripslashes( $_REQUEST['post_title'] ));
|
||||||
else if ( !empty( $_REQUEST['popuptitle'] ) ) {
|
|
||||||
$post_title = esc_html( stripslashes( $_REQUEST['popuptitle'] ));
|
|
||||||
$post_title = funky_javascript_fix( $post_title );
|
|
||||||
} else {
|
|
||||||
$post_title = '';
|
|
||||||
}
|
|
||||||
|
|
||||||
$post_content = '';
|
$post_content = '';
|
||||||
if ( !empty( $_REQUEST['content'] ) )
|
if ( !empty( $_REQUEST['content'] ) )
|
||||||
$post_content = esc_html( stripslashes( $_REQUEST['content'] ));
|
$post_content = esc_html( stripslashes( $_REQUEST['content'] ));
|
||||||
else if ( !empty( $post_title ) ) {
|
|
||||||
$text = esc_html( stripslashes( urldecode( $_REQUEST['text'] ) ) );
|
|
||||||
$text = funky_javascript_fix( $text);
|
|
||||||
$popupurl = esc_url($_REQUEST['popupurl']);
|
|
||||||
$post_content = '<a href="'.$popupurl.'">'.$post_title.'</a>'."\n$text";
|
|
||||||
}
|
|
||||||
|
|
||||||
|
$post_excerpt = '';
|
||||||
if ( !empty( $_REQUEST['excerpt'] ) )
|
if ( !empty( $_REQUEST['excerpt'] ) )
|
||||||
$post_excerpt = esc_html( stripslashes( $_REQUEST['excerpt'] ));
|
$post_excerpt = esc_html( stripslashes( $_REQUEST['excerpt'] ));
|
||||||
else
|
|
||||||
$post_excerpt = '';
|
|
||||||
|
|
||||||
$post->ID = 0;
|
$post->ID = 0;
|
||||||
$post->post_name = '';
|
$post->post_name = '';
|
||||||
|
@ -31,9 +31,7 @@ function redirect_page($page_ID) {
|
|||||||
}
|
}
|
||||||
$referer = preg_replace('|https?://[^/]+|i', '', wp_get_referer());
|
$referer = preg_replace('|https?://[^/]+|i', '', wp_get_referer());
|
||||||
|
|
||||||
if ( 'post' == $_POST['originalaction'] && !empty($_POST['mode']) && 'bookmarklet' == $_POST['mode'] ) {
|
if ( 'post' == $_POST['originalaction'] && !empty($_POST['mode']) && 'sidebar' == $_POST['mode'] ) {
|
||||||
$location = $_POST['referredby'];
|
|
||||||
} elseif ( 'post' == $_POST['originalaction'] && !empty($_POST['mode']) && 'sidebar' == $_POST['mode'] ) {
|
|
||||||
$location = 'sidebar.php?a=b';
|
$location = 'sidebar.php?a=b';
|
||||||
} elseif ( isset($_POST['save']) || isset($_POST['publish']) ) {
|
} elseif ( isset($_POST['save']) || isset($_POST['publish']) ) {
|
||||||
$status = get_post_status( $page_ID );
|
$status = get_post_status( $page_ID );
|
||||||
|
@ -31,9 +31,7 @@ function redirect_post($post_ID = '') {
|
|||||||
}
|
}
|
||||||
$referer = preg_replace('|https?://[^/]+|i', '', wp_get_referer());
|
$referer = preg_replace('|https?://[^/]+|i', '', wp_get_referer());
|
||||||
|
|
||||||
if ( !empty($_POST['mode']) && 'bookmarklet' == $_POST['mode'] ) {
|
if ( !empty($_POST['mode']) && 'sidebar' == $_POST['mode'] ) {
|
||||||
$location = $_POST['referredby'];
|
|
||||||
} elseif ( !empty($_POST['mode']) && 'sidebar' == $_POST['mode'] ) {
|
|
||||||
if ( isset($_POST['saveasdraft']) )
|
if ( isset($_POST['saveasdraft']) )
|
||||||
$location = 'sidebar.php?a=c';
|
$location = 'sidebar.php?a=c';
|
||||||
elseif ( isset($_POST['publish']) )
|
elseif ( isset($_POST['publish']) )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user