How to create more access level groups that work like Guest-Registered

Post Reply
sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Wed Mar 18, 2020 11:12 am

I want to create different articles with the same content, with the different that one of them has got some text hidden and where one just can see the full text article if one is logged in at a higher level. This can be achieved by using Guest and Registered, where the article where one can't see all text is set to Guest and is only shown to those who are not logged in, and the the full article is only shown to Registered users that are logged in.

I want to do the same for other access levels too. This is what it should look like:
  • Guest level: The article should not be viewed
  • Registered level: The article (e.g. alias: article), where some part of it is not shown, can be viewed
  • Registered+ level: The full version of the article (e.g. alias: article-full) can be viewed, but not the "sibling article" (e.g. alias: article) where some part is not shown
How to achieve this if it's possible?
Last edited by sokrates_mx5 on Wed Mar 18, 2020 12:28 pm, edited 2 times in total.

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 39465
Joined: Sat Apr 05, 2008 9:58 pm

Re: How to create more access level groups that work like Guest-Registered

Post by Webdongle » Wed Mar 18, 2020 11:23 am

Create a user group called 'Registered Plus'
Create a view level called 'Registered Plus'
In the view level called 'Registered Plus', select the user group 'Registered Plus'
The users you want to see 'Registered Plus' put them in that group as well as 'Registered'.
Find a 3rd party extension that hides parts of the Article
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"The definition of insanity is doing the same thing over and over again, but expecting different results": Albert Einstein.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Wed Mar 18, 2020 12:38 pm

Webdongle wrote:
Wed Mar 18, 2020 11:23 am
Create a user group called 'Registered Plus'
Create a view level called 'Registered Plus'
In the view level called 'Registered Plus', select the user group 'Registered Plus'
The users you want to see 'Registered Plus' put them in that group as well as 'Registered'.
Find a 3rd party extension that hides parts of the Article
Thanks for your reply. I was hopping that no 3rd party extension should be needed. I've had a quick look at the following extensions:
But I rather achieve it without any extension, since some of them had not been updated recently and ECR doesn't seam to handle images well.

I already have view levels like Registered+, but how do I make the "sibling article" from the Registered level not to be shown at the Register+ level?

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 39465
Joined: Sat Apr 05, 2008 9:58 pm

Re: How to create more access level groups that work like Guest-Registered

Post by Webdongle » Wed Mar 18, 2020 12:51 pm

afaik Articles are (by default)only one view/access level. You could try splitting the Articles into pages and create separate menu items for the pages but not sure if that would work. Alternatively use a Category blog menu item for the Article with allow unauthorised. But other than that a 3rd party extension.
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"The definition of insanity is doing the same thing over and over again, but expecting different results": Albert Einstein.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Wed Mar 18, 2020 1:42 pm

Articles that are set to Guest doesn't show for Registered users when they're signed in. What is it that make this happen? I want to create the same function for other access levels too. I don't have a problem having almost identical copies of the "same" article.

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 39465
Joined: Sat Apr 05, 2008 9:58 pm

Re: How to create more access level groups that work like Guest-Registered

Post by Webdongle » Wed Mar 18, 2020 1:49 pm

Guest user group is not selected in Registered view/access level.
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"The definition of insanity is doing the same thing over and over again, but expecting different results": Albert Einstein.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Wed Mar 18, 2020 2:36 pm

Webdongle wrote:
Wed Mar 18, 2020 1:49 pm
Guest user group is not selected in Registered view/access level.
Thanks. Then I believe I have to create another Register access level where those articles that I don't won't to be shown at the Register+ level have to be placed. I'll have to read a bit more about the ACL.

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 39465
Joined: Sat Apr 05, 2008 9:58 pm

Re: How to create more access level groups that work like Guest-Registered

Post by Webdongle » Wed Mar 18, 2020 5:23 pm

I told you that already please read https://docs.joomla.org/J3.x:Access_Con ... t_Tutorial
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"The definition of insanity is doing the same thing over and over again, but expecting different results": Albert Einstein.

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 27543
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: How to create more access level groups that work like Guest-Registered

Post by Per Yngve Berg » Wed Mar 18, 2020 5:27 pm

Registered+ will inherit from Registered when you make it a child group.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 19, 2020 9:37 am

I've read the ACL tutorial (https://docs.joomla.org/J3.x:Access_Con ... t_Tutorial) and have been testing different alternatives. For users that is granted viewing rights of Registered+ content the two "siblings" articles are shown (alias: article and alias: article-full). I can't find a solution how to make the article, which is shown for Registered (alias: article), not to be show for Registered+ users. Is this mission impossible to accomplish?

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 19, 2020 9:51 am

sokrates_mx5 wrote:
Thu Mar 19, 2020 9:37 am
I've read the ACL tutorial (https://docs.joomla.org/J3.x:Access_Con ... t_Tutorial) and have been testing different alternatives. For users that is granted viewing rights of Registered+ content the two "siblings" articles are shown (alias: article and alias: article-full). I can't find a solution how to make the article, which is shown for Registered (alias: article), not to be show for Registered+ users. Is this mission impossible to accomplish?
It might not be that strange that it doesn't work since users that are assigned Register+ viewing rights to start with are assigned to the user group Registered.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 19, 2020 10:33 am

This is how I would like it to work:

Code: Select all

if(logged in) {
  if(registered+) {
    "show": article-full;
  }
  else {
    "show": article;
  }
}

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 39465
Joined: Sat Apr 05, 2008 9:58 pm

Re: How to create more access level groups that work like Guest-Registered

Post by Webdongle » Thu Mar 19, 2020 10:45 am

If a user is in two groups they will see everything in view levels that both those user groups are assigned to.
If a user is in only one group they will see only see things in view levels that group is assigned to.
If two user groups are assigned to a view level then users in both groups see everything in that view level.
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"The definition of insanity is doing the same thing over and over again, but expecting different results": Albert Einstein.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 19, 2020 11:13 am

Webdongle wrote:
Thu Mar 19, 2020 10:45 am
If a user is in two groups they will see everything in view levels that both those user groups are assigned to.
If a user is in only one group they will see only see things in view levels that group is assigned to.
If two user groups are assigned to a view level then users in both groups see everything in that view level.
Yes, there is my problem.

I just want to be able to create a "sibling" article occasionally. Therefore the users that are assigned to the user group Registered+ will also be assigned to the user group Registered. As a consequence, the two "siblings" articles will be shown for those users that are assigned Registered and Registered+ :(

So far, I haven't come across any extension that does the job in a way that I'm satisfied with.

I wounder if the K2 extension (https://getk2.org/) could do the job?

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 19, 2020 11:51 am

A solution could be to create a new user group "Registered - Not Registered+" that Registered users also could be assigned to. This could be done either manually or automatically like described in the following thread:

viewtopic.php?t=868308

Then at the viewing access level I also have a Level Name called "Registered - Not Registered+" that is assigned to the user group "Registered - Not Registered+" instead of "Registered".

This solution require a bit of manual work, but I got a limited amount of registered users so it's doable.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 19, 2020 12:20 pm

sokrates_mx5 wrote:
Thu Mar 19, 2020 11:51 am
A solution could be to create a new user group "Registered - Not Registered+" that Registered users also could be assigned to. This could be done either manually or automatically like described in the following thread:

viewtopic.php?t=868308

Then at the viewing access level I also have a Level Name called "Registered - Not Registered+" that is assigned to the user group "Registered - Not Registered+" instead of "Registered".

This solution require a bit of manual work, but I got a limited amount of registered users so it's doable.
It works!

Besides that the user group "Registered - Not Registered+" has to be assigned to registered users, one also have to be careful when upgrading users from "Registered - Not Registered+" to "Registered+" and remember to uncheck the checkbox for "Registered - Not Registered+". It would have been handy to change the checkboxes of for these two user groups with a radio button, but I guess there're no simple solution to so.

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Thu Mar 26, 2020 6:32 pm

The Conditional Content Extension does the job well too:
https://extensions.joomla.org/extension ... l-content/

User avatar
darb
Joomla! Ace
Joomla! Ace
Posts: 1705
Joined: Thu Jul 06, 2006 12:57 pm
Location: Stockholm Sweden
Contact:

Re: How to create more access level groups that work like Guest-Registered

Post by darb » Sat Mar 28, 2020 10:49 am

Maybe Peter at Regular Labs can help with tweaking "Conditional content" that could do this I guess https://www.regularlabs.com/extensions/ ... ed-options

sokrates_mx5
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 242
Joined: Tue Mar 24, 2009 12:30 pm

Re: How to create more access level groups that work like Guest-Registered

Post by sokrates_mx5 » Sat Mar 28, 2020 11:27 am

darb wrote:
Sat Mar 28, 2020 10:49 am
Maybe Peter at Regular Labs can help with tweaking "Conditional content" that could do this I guess https://www.regularlabs.com/extensions/ ... ed-options
"Conditional content" does the job well already :)

It works well with a Slideshow CK put (https://extensions.joomla.org/extension/slideshow-ck/) into Modules Anywhere (https://extensions.joomla.org/extension ... -anywhere/) and an MP3 audio in AllVideos (https://extensions.joomla.org/extension/allvideos/). The "show-else" is very usefull if one wants to show an alternative. After these Extensions have been installed one just put in some code into the article :)

Code: Select all

{show accesslevels="Registered Plus"}

{module Slideshow CK}

{mp3}XXX{/mp3}

{show-else}

[Hidden content - URL link]

{/show}


Post Reply

Return to “Access Control List (ACL) in Joomla! 3.x”