Make WordPress Core

Changeset 10094


Ignore:
Timestamp:
12/07/2008 03:39:00 AM (17 years ago)
Author:
azaozz
Message:

Show "Post submitted" message when contributors submit a post for review, props mdawaffe, fixes #8519

Location:
trunk/wp-admin
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit-form-advanced.php

    r10088 r10094  
    2626$messages[6] = sprintf(__('Post published. <a href="%s">View post</a>'), get_permalink($post_ID));
    2727$messages[7] = __('Post saved.');
     28$messages[8] = sprintf(__('Post submitted. <a href="%s">Preview post</a>'), add_query_arg( 'preview', 'true', get_permalink($post_ID) ) );
    2829
    2930if ( isset($_GET['revision']) )
  • trunk/wp-admin/edit-page-form.php

    r10091 r10094  
    2424$messages[4] = __('Page updated.');
    2525$messages[5] = sprintf(__('Page published. <a href="%s">View page</a>'), get_permalink($post_ID));
     26$messages[6] = sprintf(__('Page submitted. <a href="%s">Preview page</a>'), add_query_arg( 'preview', 'true', get_permalink($post_ID) ) );
    2627
    2728if ( isset($_GET['revision']) )
  • trunk/wp-admin/page.php

    r9998 r10094  
    4343            ), get_edit_post_link( $page_ID, 'url' ) );
    4444        else {
    45             if ( isset( $_POST['publish'] ) )
    46                 $location = add_query_arg( 'message', 5, get_edit_post_link( $page_ID, 'url' ) );
    47             else
     45            if ( isset( $_POST['publish'] ) ) {
     46                if ( 'pending' == get_post_status( $page_ID ) )
     47                    $location = add_query_arg( 'message', 6, get_edit_post_link( $page_ID, 'url' ) );
     48                else
     49                    $location = add_query_arg( 'message', 5, get_edit_post_link( $page_ID, 'url' ) );
     50            } else {
    4851                $location = add_query_arg( 'message', 4, get_edit_post_link( $page_ID, 'url' ) );
     52            }
    4953        }
    5054    } elseif ( isset($_POST['addmeta']) ) {
  • trunk/wp-admin/post.php

    r9998 r10094  
    4646            ), get_edit_post_link( $post_ID, 'url' ) );
    4747        else {
    48             if ( isset( $_POST['publish'] ) )
    49                 $location = add_query_arg( 'message', 6, get_edit_post_link( $post_ID, 'url' ) );
    50             else
     48            if ( isset( $_POST['publish'] ) ) {
     49                if ( 'pending' == get_post_status( $post_ID ) )
     50                    $location = add_query_arg( 'message', 8, get_edit_post_link( $post_ID, 'url' ) );
     51                else
     52                    $location = add_query_arg( 'message', 6, get_edit_post_link( $post_ID, 'url' ) );
     53            } else {
    5154                $location = add_query_arg( 'message', 7, get_edit_post_link( $post_ID, 'url' ) );
     55            }
    5256        }
    5357    } elseif (isset($_POST['addmeta']) && $_POST['addmeta']) {
Note: See TracChangeset for help on using the changeset viewer.