Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
in Q2A Core by
edited by


i find a little problem on the Top menu. When i go to the

admin => Pages, i desactivate the users (navigation links). than is already hide and we can not acces to see the user on the Top Menu.. 

But if i go to the navigator Firefox, Chrome and i add this " ?qa=users " after the link, everyone with a account can see the user. 

Ex: localhost/Q&A/?qa=users (user menu is desactivate but can see if you are connected)

an idea ? 

Thank you very much all

Check my edited answer may helps you...

1 Answer

+2 votes
edited by

This is default Q2A behavior, which should not be. The url should only be available if menu item.

Hopping fix in next releases.


I quickly done core hack.. in file qa-include/qa-page-users.php 

Find on line #50


Below that place this code

if(!array_key_exists('user', $qa_content['navigation']['main'])){
    header('HTTP/1.0 404 Not Found');


    return $qa_content;

Added code on Gist https://gist.github.com/q2amarket/8406457

HI jatin,

Thank you again for you help. Just a little question more.

If i want to give some privileges on the Navigation menu, do you think is possible ?

Ex: i activate the users link on the Top-Menu, and this link can be access only for administrator or modearator.

Actually i use a plugin "permission2categories", but the privileges is available only for the page, not for the navigation link.

Thank you
I need to try but my logic is saying you can use unset. Will try later today or tomorrow.
Hi jatin,

for my last question, it's little confuse maybe about the permission.

I already use your code, works perfect. Now to explain more precise about this code,

i would like If i go to admin and activate the user link on the main menu, give an access only for the admin and moderator.

What do you think ?  

Thank you
Okay but I think I found another way to do without touching core files. But busy at the moment so if you are in hurry you can go on with this code later I will share the code once get time.. Regarding to your query.. you can check anything you want to check before redirecting users.. after all it's your choice :))