Css and function issue on author archive page

1) The messed up layout It looks like you’re missing one closing </div> in your markup. Adding it on a line between <?php endif; ?> and <?php get_sidebar(); ?> should do the trick. As a side note, you have h3 nested inside a h4 which is invalid markup. 2) Adding styling to your site In … Read more

Set featured image as hero image on each page

You need to look at how your theme is rendering the hero image. Then, before it does so, add an if block which checks for a featured image. If a featured image exists, replace the hero image with it. Your code will look something like this. if ( has_post_thumbnail() ) { // render hero image … Read more

allow user to create a draft post but not publish wordpress

Use wp_insert_post_data filter. Then check the user role. If user have specific role set-up post status. ( I don’t test below script) add_filter( ‘wp_insert_post_data’, ‘filter_handler’, ’99’); function filter_handler( $data ) { $user = wp_get_current_user(); $userRole = $user->roles ? $user->roles[0] : false; if ( $userRole === ‘author’) { $data[‘post_status’] = ‘pending’; } return $data; }