-
AuthorPosts
-
jamjodesign Friend
jamjodesign
- Join date:
- June 2008
- Posts:
- 432
- Downloads:
- 27
- Uploads:
- 40
- Thanks:
- 59
- Thanked:
- 14 times in 3 posts
May 11, 2017 at 11:23 am #1033221Hi there, While on the site you will see that there is a Home option in the main navigation bar that I am sure is on most websites to be honest.
My question is how to remove this when users are signed into the website. When signed in as a user I would expect a “home” option to bring me to the Dashboard as opposed to the original Sign in page. This seems redundant when a user is already logged in.
So how to hide a menu item when a user is logged in?
Thanks in advance,
Jamesjamjodesign Friendjamjodesign
- Join date:
- June 2008
- Posts:
- 432
- Downloads:
- 27
- Uploads:
- 40
- Thanks:
- 59
- Thanked:
- 14 times in 3 posts
May 11, 2017 at 11:52 am #1033230As means of a quick update, I do know you can set a menu item to guest but when I set home to guest the issue is that if a user closes the browser and returns and is still logged in or clicks on the logo to bring them home they get a 404 like this: http://recordit.co/6zNjiNUZkZ
So maybe there is just a piece of css that could hide the home menu item when logged in but if the user does happen to want to go direct to the site root that they do not get the 404.
Or alternatively if the user is forced to the dashboard as their new default home option when logged in to avoid this 404?
I am not sure of the best work around here so any help would be much appreciated.
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
May 12, 2017 at 8:01 am #1033497Hi James,
It’s so clear that when you assign that ‘Home’ item to ‘Guest’ user group, logged in users (who belong to other user group) can’t access that page and of course will direct to 404 page.
I think you can set the Link for the logo to Dashboard page by default, I just set it for you, kindly check.
Regards
jamjodesign Friendjamjodesign
- Join date:
- June 2008
- Posts:
- 432
- Downloads:
- 27
- Uploads:
- 40
- Thanks:
- 59
- Thanked:
- 14 times in 3 posts
May 12, 2017 at 9:48 am #1033537Hi Saguaros, that unfortunately is not going to work. The reason it does not work is because most users do not care to logout of the site they just close the browser and then visit again a short time later and type in my website address directly and therefore will get a 403 once more!!! like so: http://recordit.co/WYDHc5bvp7
I need a solution whereby what you have done is correct but that if a user does happen to type in my url and is logged in the site does not display an error – they get redirected to the dashboard or the homepage does infact show up?
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
May 15, 2017 at 10:11 am #1034105When you set the link for logo, even that user closes the browser, when he is back, clicking logo still redirects to dashboard page, is that not what you want to achieve?
jamjodesign Friendjamjodesign
- Join date:
- June 2008
- Posts:
- 432
- Downloads:
- 27
- Uploads:
- 40
- Thanks:
- 59
- Thanked:
- 14 times in 3 posts
May 30, 2017 at 10:00 am #1038065Hi Saguaros, that unfortunately is not going to work. The reason it does not work is because most users do not care to logout of the site they just close the browser and then visit again a short time later and type in my website address directly and therefore will get a 403 once more!!! like so: http://recordit.co/WYDHc5bvp7
I have tried to maybe add a second home link to another menu so that an error does not appear on the homepage but basically its not working either. Any other ideas on this as I assumed this was going to be ok on a network type site. Thanks for time on this but its very confusing for users right now.
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
May 31, 2017 at 4:12 am #1038312Actually, your request is still confused with me.
The normal scenario is (other clients asked):
- A Guest will not see some menu items
- After logging in, he will see them
But your request is vice versa, you want to hide item after user login. The only way in Joomla is you need to set that item to user group for Guest only so after user login, he will not see it.
jamjodesign Friendjamjodesign
- Join date:
- June 2008
- Posts:
- 432
- Downloads:
- 27
- Uploads:
- 40
- Thanks:
- 59
- Thanked:
- 14 times in 3 posts
May 31, 2017 at 7:41 am #1038360@saguaros, its really not that confusing. This is a network website. The homepage of any network like facebook or linkedin or twitter explains the site and has a login module. Likewise my site and your template has a homepage and login module. When you login to facebook or twitter and you are logged in when you visit facebook.com you cannot obviously see the homepage anymore – that would be just confusing frankly. So when the user is logged in they should not see the homepage just like any other network.
So my problem is if I set the home to guest only and the user logs in that works great – exactly as you describe. The issue is if they do not logout and the session is stored as them being logged in and they come back via google or just type in my website url they get a 404 page – they should not! I do not mind a returning user seeing the homepage briefly just to avoid the 404 – I know thisis a limitation of Joomla – I just do not need it appearing in the main menu!
So I hope this is now clearer.
Basically is the main menu area here on my site http://recordit.co/6eHuprNamu is this a module?
Perhaps if this was a module one could do the following.- For home menu item, set public access. This will no longer trigger the 404 error.
- Then have 2 menus as below and assign them to their own module, each module having the same position.
menu1(has home menu item) moduleA(assign on all pages, access guest user only)
menu2(has no home menu item) moduleB(assign on all pages, access registered user only)
moduleA will display menu1 and moduleB will display menu2. These 2 modules will show on every page but the module that appears will be according to the viewer’s user group. The only issue here is whether or not this main menu is a module position in your template?
.Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
June 2, 2017 at 1:28 am #1038895Let me see if it can be done.
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
June 2, 2017 at 8:19 am #1038981Hi,
The menu is not a module, it belongs to T3 framework.
For the way of showing the page having feature like Facebook as you mentioned, at this moment, Joomla doesn’t provide way to configure like that. It can be done as I suggested above only.
Another way is that you must customize so that it will check if user already logged in, he will be redirected to appropriate page.
Regards
-
AuthorPosts
This topic contains 9 replies, has 2 voices, and was last updated by Saguaros 7 years, 6 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum