functions, but being a newbie to PHP I don't think I'm getting the syntax right. Specific code is beneath the jump.
The basic idea is that I want some parts of my site to be front-facing, while retaining basic privacy of user content against non-users and search robots. Part of this includes my custom made widget areas, here
, and part of this also includes custom loops that are displaying specific categories on my site, which is pretty typical loop-type stuff.
I've tried a couple of different ways to wrap the is_user_logged_in () loop around these different snippets of code, but I think that my general lack of knowledge in PHP is making it not work properly, either throwing errors, or not throwing errors but also not working. This
is an example of a current attempt which is currently throwing "Parse error: syntax error, unexpected T_ELSE in the-file-name.php on line 55
" when it tries to render.
Apart from the main question, is there a better way to do this that I'm missing? I know that I can include not-logged-in redirect code in to my functions.php file, but the project manager is concerned that this sort of redirect would also be confusing to our users, who are typically younger and less technologically savvy.