Where should I hook into the admin backend to check and see if the user is “active” as defined by the Membership Plugin.
Or in other words, where can I hook into the WP admin header to check an if-statement and redirect if it fails?
Where should I hook into the admin backend to check and see if the user is “active” as defined by the Membership Plugin.
Or in other words, where can I hook into the WP admin header to check an if-statement and redirect if it fails?
You must be logged in to post a comment.
Not sure about the Membership plug-in bit, but
admin_init
will be your best bet. I assume that you don’t actually what to hook into the admin header though – this would beadmin_head
oradmin_head-(plugin_page)
– but you cannot redirect after these hooks (headers already sent).