管理者権限のユーザーでも新規投稿時にステータスpost_statusをレビュー待ちpendingにしたかったので。
function.phpに追加。
//新規投稿のステータス初期値を「レビュー待ち」にする
function post_function($data){
//処理
$data['post_status'] = 'pending';
return $data;
}
add_filter('wp_insert_post_data', 'post_function');
コメントを残す