Hiding content from users not logged in, a few problems with it
I’ve managed to find a way to display content on my website, using the following little code:
<?php if ($user_ID) : ?>
Random xhtml-code you want to display depending on user status (logged in or logged out).
<?php endif; ?>
But the problem is, that echoing the contents of $user_ID doesn’t return anything when trying to use it in the following files:
But! It works in archives.php!
Which kind of goes way beyond me. I want to exclude content for the logged out users on all instances and am looking for anything that can help me achieve that goal.
So please help me out here guys & gals.
- The topic ‘Hiding content from users not logged in, a few problems with it’ is closed to new replies.