This topic contains 4 replies, has 2 voices. Last updated by John Asanga 3 years, 5 months ago.
Topic Author | Topic |
---|---|
Posted: Tuesday Jul 30th, 2013 at 2:40 pm #54404 | |
I added this to my child theme functions.php. add_action (“wp”, “my_custom_capabilities”, 1); if (fnmatch (“/members”, $_SERVER[“REQUEST_URI”]) && !current_user_can(“access_s2member_level2”)) { if (fnmatch (“/members/[abcdefghijklmnopqrstuvwxyz1234567890]”, $_SERVER[“REQUEST_URI”]) && !current_user_can (“access_s2member_level2”)) if (fnmatch (“/members/”.S2MEMBER_CURRENT_USER_LOGIN, $_SERVER[“REQUEST_URI”]) && !current_user_can (“access_s2member_level2”)) // If any of the URIs above matched, but the user did not have the necessary ccap, redirect to Membership Options. if (FALSE === $allowed) { |