9

You need to change the Group parent to registered (or any other than Public, Guest). As users from Public usergroup are not allowed to login at website. Or you need to change the permissions of your newly created usergroup.


9

To get an array of groups the currently logged in user belong to, you can use the following: $user = JFactory::getUser(); $groups = JAccess::getGroupsByUser($user->id); var_dump($groups); To get the names of these groups, you can run a database query (add after the code above) $user = JFactory::getUser(); $groups = JAccess::getGroupsByUser($user-&...


7

That will work if isRoot has been set. But, it requires a call to JUser::authorise() having been completed first. This snippet would work at all times: $user = JFactory::getUser(); $isroot = $user->authorise('core.admin');


5

Joomla also provides a plugin named User-Profile using which you can maintain additional user related information. This plugins is pre-installed with joomla installation. In case this plugin is not sufficient enough to handle your requirement then you can either modify this extension to collect more information or you can create similar extension.


5

You can either use this: $user = JFactory::getUser(); if($user->id != 0) { // you are a member } else { // you are a guest } or this: $user = JFactory::getUser(); if($user->guest) { // you are a guest } else { // you are a member } Bother are the same with most likely nano seconds in performance, in regards to speed.


5

I usually do something like this: <?php $user = JFactory::getUser(); if ($user->guest) { // User is not logged in } else { //User is logged in } ?> Take a look at the Joomla Documentation.


5

Provided that you have admin access then you can follow the steps below In the site admin area and go to the Users menu Select the Groups menu item User group select group menu Find the group you want to move to a different parent and click on it to open it Select the group Change the group title if required. Change the parent by selecting the down ...


4

Besides the direct programmatic method to conditionally show different contents (JFactory::getUser()->guest), there's an alternative to create a Guest group to identify this specific set of users; in this way, the content can be managed either at the CMS level with the regular administrative tools or in a plugin with Access Control List controls: How do you ...


4

I'm not sure if Joomla has a better way to do this, but you can create your own function and query the database: function getGroupId($groupName){ $db = JFactory::getDBO(); $db->setQuery($db->getQuery(true) ->select('*') ->from("#__usergroups") ); $groups = $db->loadRowList(); foreach ($groups as $group) { ...


4

Default ACL Neil said it right - it's recommended to give users as many permissions / privileges as they actually need or have to. It is very likely that for this person the Manager user group would be sufficient, If for example you only want this person to be dealing with content. Custom ACL However, your needs may be different - so keep in mind that ...


3

It's likely that your developer configured one or more menu items or articles to be available to restricted users only (or another custom user group). You can edit this by going to Menus -> [YOUR MENU]. You'll see something like this: This is called access control, and anything different than Public will require username/password in order to view. When ...


3

As per the current behavior of Joomla user can be in multiple usergroups and there is no hidden or inbuilt functionality available which can be utilized to implement such scenario. But obviously there are some alternates to everything. You can develop a plugin which will maintain a mapping of mutually exclusive user groups like User-group A is mutually ...


3

To answer the actual question, this code will give you a listbox of UserIDs and Names. Retrieving all the extra data would then just be a SQL select statement $myGroupID = 2; //Your User Group to list $db = JFactory::getDbo(); $query = $db->getQuery(true); $query->select('a.id as value, a.name as text'); $query->from($db->quoteName('#__users')....


3

As the comments say, try the Login Redirect Extensions, but I had the same scenario, and opted to use a plugin called Nomad. What I liked about it (though you may not) is that it doesn't use the typical redirect that most of the similar plugins use, but instead dynamically changes their home page, based on the User Group. The net effect is that visitors ...


3

Obviously it is something wrong with your ACL. Usually it's hard to give a reply with the actual solution in such questions with the first try, as ACL needs a hands-on investigation, or otherwise the complete ACL configuration, in order for someone to try to understand or replicate an issue. But in your case, I would guess that you haven't added Viewing ...


3

You can add the group by directly invoking the save function in com_users component model. $group = array('id'=>0, 'title'=>'Group Title', 'parent_id'=>1); JLoader::import('joomla.application.component.model'); JLoader::import('group', JPATH_ADMINISTRATOR.'/components/com_users/models'); $groupModel = JModelLegacy::getInstance( 'Group', 'UsersModel'...


2

It is not only creating a new user group, but also what Permissions and access the users in a user group will have. If you have set your user group as a child of the Public user group, then it won't have Site login permissions. You should either go in the Global Configuration -> Permissions and assign to it the right permissions, "Site Login" and only for ...


2

It seems that the issue caused by the default limit of max_input_vars of php and to the fact that the page is trying to load a significant amount of fields. The issue has been discussed here and here. As solution, it is suggested to increase the php_max_input_vars on the server. Update: The continue of this issue with a solution to overcome the ...


2

You can take a look at all the plugin events and try hooking into one of those: http://docs.joomla.org/Plugin/Events The idea is that you hook into one of those events and run a check on how many users are in that group. This is how you write a plugin: http://docs.joomla.org/J2.5:Creating_a_Plugin_for_Joomla As you can see, it is unbelievably easy


2

I have just checked save method in profile model. There is line as follows. line no 362-363. // Null the user groups so they don't get overwritten $user->groups = null; I commented out that line. It works fine. I don't know which area will affect after commenting out that line.


2

User content restriction You can use a plugin called OSD Content Restriction. This little plugin will let you define who can see your content based on several parameters. What is shown or hidden can be determined by six different variables, namely the user group, the user, the author group, the author, if on the homepage or if an article is featured. In ...


2

Aha, Just updated Jomsocial to 3.2.1.4 and the change log says: "ACL of user randomly changes when using groups." We'll see if that fixed it. http://www.jomsocial.com/change-log/3214 Update: Yes, updating to this version fixed the issue.


2

This is not possible by default in Joomla, although users of lower usergroups can only assign users to groups up to the level of their group. Furthermore, Joomla's default user management occurs in the backend. I am not sure you would want to give backend access to so many users. You should look for a front-end solution. Actually, it would be better to ...


2

You can't edit user data in onUserBeforeSave and onUserAfterSave event. This is just a copy of what will/was saved. It would be better to: use onUserAfterSave event get user object after save $user = JFactory::getUser($user_id) where $user_id is id of a user you want to modify modify user groups like this $user->groups = Array($new_user_group) save user $...


2

You can create your own function that you can call to get the group id as : public function getGroupId($groupName) { $db = JFactory::getDbo(); $select = "select id from #__usergroups where title='".$groupName."'"; $db->setQuery($select); $db->query(); $data = $db->loadObject(); $groupId = $data->id; if(empty($groupId)) $...


2

Please avoid framework changes. This will lead you to system/functionality break after update. Create a User type plugin and work in it on event called onUserAfterSave.That way you will be update-safe. Add proper parameter fields(group0 and group1) to plugin XML file. Plugins have their own configuration so you cant get those parameters every time you need ...


2

The way to do it is by overriding the view template. 1 - First you have to understand how to create an override of a component view. This tutorial may help you: https://www.ostraining.com/blog/joomla/overrides/ 2 - Then you have to locate the code that renders the table. There is not much we can do here without seeing the code, but I assume that you may ...


2

It is usually best practice to only add users to the group(s) that they need e.g. Registered, Author, Editor, Manager, Administrator etc. to perform their role. For an explanation of the different default groups and privileges, see: https://docs.joomla.org/J3.x:Access_Control_List_Tutorial#Default_Groups joomla.com is a little different as many of the ...


2

You can create a new Access Level for your site, from here you can control which users can view which objects on your site, like modules. You can create your new access level in Users > Access Level Now, assign to your user group the new access level, then that users can view the modules assigned to this access level. In your modules you can see an option ...


2

That is a well-known issue, see post Preparing for K2 questions So, disable user registration in Joomla and possibly disable K2 user management unless your site need it very bad. Needless to say that your site is outdated and that you need to update it ASAP, I'm sure you know that very well, especially after such spam-bomb attack your site have faced. ...


Only top voted, non community-wiki answers of a minimum length are eligible