Home › Forums › CSS › Hide element if WordPress user logged in › Reply To: Hide element if WordPress user logged in
April 6, 2019 at 9:56 am #286008
What you can do is use a function to add a class in the body if user is logged in. For example:
And then target the buttons you want to disable like this.
check if WP doesn’t automatically add classes on the body (or in any other parent) when the user is logged in where you can use them.