Malin revised this gist . Go to revision
1 file changed, 7 insertions
redirect-logout-to-home.php(file created)
| @@ -0,0 +1,7 @@ | |||
| 1 | + | // redirect Wordpress logout to home | |
| 2 | + | ||
| 3 | + | add_action('wp_logout','auto_redirect_after_logout'); | |
| 4 | + | function auto_redirect_after_logout(){ | |
| 5 | + | wp_redirect(home_url()); | |
| 6 | + | exit(); | |
| 7 | + | } | |
Newer
Older