redirect WP Logout page to Homepage wordpress...

Sometimes in wordpress websites the page does not redirect to the home page after logout. or we can say when we hit on the Logout button it does not redirected properlly. The Answer is really simple we just need to add a hook for this. IN theme functions.php file Put the Below Code:

add_action('wp_logout','go_home');
function go_home(){
  wp_redirect( home_url() );
  exit();
}


It's done....!!