go back.' ), attribute_escape( stripslashes( ( isset( $_GET['_wp_original_http_referer'] ) ? $_GET['_wp_original_http_referer'] : '') ) ) ); $messages[2] = __('Custom field updated.'); $messages[3] = __('Custom field deleted.'); $messages[4] = __('Page updated.'); if ( isset($_GET['revision']) ) $messages[5] = sprintf( __('Page restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ); $notice = false; $notices[1] = __( 'There is an autosave of this page that is more recent than the version below. View the autosave.' ); if ( 0 == $post_ID) { $form_action = 'post'; $nonce_action = 'add-page'; $temp_ID = -1 * time(); // don't change this formula without looking at wp_write_post() $form_extra = ""; } else { $post_ID = (int) $post_ID; $form_action = 'editpost'; $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 ) ) $notice = sprintf( $notices[1], get_edit_post_link( $autosave->ID ) ); } $temp_ID = (int) $temp_ID; $user_ID = (int) $user_ID; ?>