Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
150 views
in Plugins by
Please Friends, i am new to Question2Answer. Please how can i hide some pages for non login users, e.g, i want to hide the user page for quests visit and also hide some other pages for non login users except they login or register before they can access them?

Please immediate answer is highly needed please.

thank you all.
by
Please friends, come in and help me with this please..

1 Answer

+1 vote
by
edited by

put the following function inside the class in this file: https://github.com/q2a/question2answer/blob/dev/qa-theme/SnowFlat/qa-theme.php

public function initialize()
{
     if (!qa_is_logged_in()) {
         if (isset ($this->content['navigation']['main']['user']));
         unset ($this->content['navigation']['main']['user']);
     }
    qa_html_theme_base::initialize();
}
...