X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/449d082fcc4873c1f7d363a0d9f7409be7f6e77d..9c40b4d36daed9e28e48a5fe9205c32557195a4b:/wp-admin/edit-page-form.php?ds=sidebyside
diff --git a/wp-admin/edit-page-form.php b/wp-admin/edit-page-form.php
index 5d1caea0..2d436be7 100644
--- a/wp-admin/edit-page-form.php
+++ b/wp-admin/edit-page-form.php
@@ -18,10 +18,9 @@ if ( ! isset( $temp_ID ) )
if ( isset($_GET['message']) )
$_GET['message'] = absint( $_GET['message'] );
-$messages[1] = sprintf( __( 'Page updated. Continue editing below or go back.' ), attribute_escape( stripslashes( ( isset( $_GET['_wp_original_http_referer'] ) ? $_GET['_wp_original_http_referer'] : '') ) ) );
+$messages[1] = sprintf(__('Page updated. View page'), get_permalink($post_ID));
$messages[2] = __('Custom field updated.');
$messages[3] = __('Custom field deleted.');
-$messages[4] = __('Page updated.');
$messages[5] = sprintf(__('Page published. View page'), get_permalink($post_ID));
$messages[6] = sprintf(__('Page submitted. Preview page'), add_query_arg( 'preview', 'true', get_permalink($post_ID) ) );
@@ -42,7 +41,7 @@ if ( 0 == $post_ID) {
$nonce_action = 'update-page_' . $post_ID;
$form_extra = "";
$autosave = wp_get_post_autosave( $post_ID );
- if ( $autosave && mysql2date( 'U', $autosave->post_modified_gmt ) > mysql2date( 'U', $post->post_modified_gmt ) )
+ if ( $autosave && mysql2date( 'U', $autosave->post_modified_gmt, false ) > mysql2date( 'U', $post->post_modified_gmt, false ) )
$notice = sprintf( $notices[1], get_edit_post_link( $autosave->ID ) );
}
@@ -67,22 +66,29 @@ function page_submit_meta_box($post) {
-
+
post_status && 'future' != $post->post_status && 'pending' != $post->post_status ) { ?>
-post_status ) { ?>style="display:none" type="submit" name="save" id="save-post" value="" tabindex="4" class="button button-highlighted" />
+post_status ) { ?>style="display:none" type="submit" name="save" id="save-post" value="" tabindex="4" class="button button-highlighted" />
post_status && $can_publish ) { ?>
-
+
-post_status ? clean_url(get_permalink($post->ID)) : clean_url(apply_filters('preview_post_link', add_query_arg('preview', 'true', get_permalink($post->ID)))); ?>
-
-
+post_status ) {
+ $preview_link = esc_url(get_permalink($post->ID));
+ $preview_button = __('Preview Changes');
+} else {
+ $preview_link = esc_url(apply_filters('preview_post_link', add_query_arg('preview', 'true', get_permalink($post->ID))));
+ $preview_button = __('Preview');
+}
+?>
+
@@ -92,7 +98,7 @@ function page_submit_meta_box($post) {
-
+
post_status ) {
case 'private':
@@ -112,12 +118,12 @@ switch ( $post->post_status ) {
break;
}
?>
-
+
post_status || 'private' == $post->post_status || $can_publish ) { ?>
post_status ) { ?>style="display:none;" class="edit-post-status hide-if-no-js" tabindex='4'>
-
+
-
post_status ) {
$post->post_password = '';
@@ -152,29 +158,29 @@ if ( 'private' == $post->post_status ) {
$visibility_trans = __('Public');
}
-?>
+echo esc_html( $visibility_trans ); ?>
+
+
ID ) {
if ( 'future' == $post->post_status ) { // scheduled for publishing at a future date
$stamp = __('Scheduled for:
%1$s');
@@ -192,15 +198,14 @@ if ( 0 != $post->ID ) {
$stamp = __('Publish
immediately');
$date = date_i18n( $datef, strtotime( current_time('mysql') ) );
}
-?>
-
+
+if ( $can_publish ) : // Contributors don't get to choose the date of publish ?>
-
+
@@ -211,29 +216,32 @@ if ( 0 != $post->ID ) {
post_status, array('publish', 'future', 'private') ) || 0 == $post->ID ) { ?>
-
- post_date_gmt) && time() < strtotime( $post->post_date_gmt . ' +0000' ) ) : ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+post_date_gmt) && time() < strtotime( $post->post_date_gmt . ' +0000' ) ) : ?>
+
+
+
+
+
+
+
+
+
+
+
+
@@ -253,7 +261,7 @@ function page_password_meta_box($post){
?>
-
+
-
+
$post->ID, 'selected' => $post->post_parent, 'name' => 'parent_id', 'show_option_none' => __('Main Page (no parent)'), 'sort_column'=> 'menu_order, post_title')); ?>
+ if ( 0 != count( get_page_templates() ) ) { ?>
-