wp_update_post behaves differently for different user role

I solved this problem by creating a new user type with unfiltered_html set to true $result = add_role( ‘jobseeker’, __( ‘Job Seeker’ ), array( ‘read’ => true, ‘edit_posts’ => true, ‘delete_posts’ => true, ‘delete_published_posts’ => true, ‘upload_files’ => true, ‘edit_others_posts’ => false, ‘delete_others_posts’ => false, ‘unfiltered_html’ => true, //this line does the magic ) ); … Read more

Change custom post status to draft before today

Do the other post have to be set to draft? Or would just showing today’s post work? If just showing today’s post works you could do something like the following $today = getdate(); $args = array( ‘category_name’ => ‘event’, ‘posts_per_page’ => 5, ‘year’ => $today[“year”], ‘monthnum’ => $today[“mon”], ‘day’ => $today[“mday”] ); query_posts( $args );