Created
May 14, 2019 04:39
-
-
Save mahbubme/1ef8665216b9d82d1b97929fe1e62d83 to your computer and use it in GitHub Desktop.
Hide posts tab from WPUF account page
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function wpuf_sections_customize($sections){ | |
$posts_tab_index = null; | |
foreach ($sections as $index => $value) { | |
if ($value['slug'] == 'posts') { | |
$posts_tab_index = $index; | |
} | |
} | |
unset($sections[$posts_tab_index]); | |
return $sections; | |
} | |
add_filter('wpuf_account_sections', 'wpuf_sections_customize'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment