WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/14/2004 12:41:09 PM (17 years ago)
Author:
saxmatt
Message:

Initial functionality so level 1 users may be allowed to publish or just post drafts.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/post.php

    r1644 r1656  
    6767
    6868        if (empty($post_status)) $post_status = 'draft';
     69        // Double-check
     70        if ( 'publish' == $post_status && 1 == $user_level && 2 != get_option('new_users_can_blog') )
     71            $post_status = 'draft';
    6972        $comment_status = $_POST['comment_status'];
    7073        if (empty($comment_status)) $comment_status = get_settings('default_comment_status');
     
    323326   
    324327    if (isset($_POST['publish'])) $post_status = 'publish';
     328    // Double-check
     329    if ( 'publish' == $post_status && 1 == $user_level && 2 != get_option('new_users_can_blog') )
     330        $post_status = 'draft';
    325331
    326332    if (($user_level > 4) && (!empty($_POST['edit_date']))) {
Note: See TracChangeset for help on using the changeset viewer.