I added a function to my website that displays a custom nav for logged in members only. I need to add another condition (that it will not show on certain pages even if someone is logged in). Anyone know how to do this? I can go according to the page IDs.
This is the code I have SO FAR:
function add_notification_header() {
if (is_user_logged_in()) {
nav content added here
}
}
add_action( 'wp_head', 'add_notification_header' );
In other words I need to add another “if” , aka if page ID is not a and y and z… - anyone know how to do this? Can I have 2 “if” in one function or is there a different way to write it once there are 2 conditions?
Thanks!