As the title says "Organic Groups Register" doesn't show any groups to select on the registration page. My groups are public.

I noticed inside "og_register_form_user_register_form_alter", an empty array is returned by "og_register_get_groups".

I upgraded from Drupal 6 but completely removed OG, even removed all the tables and then reinstalled.

CommentFileSizeAuthor
#6 og_register.module.patch510 bytesAndrew M Riley
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

amitaibu’s picture

Category: bug » support
Priority: Major » Normal
Status: Active » Fixed

You should add og-register field to the group.

hoomanb’s picture

Status: Fixed » Active

Thanks that was a good start, but didn't help:

First, in og_register.module, there is a

define('GROUP_REGISTER_FIELD', 'group_register');

Since the field name didn't start with 'field_' I had to manually add it.

Then I noticed another bug in og_register.module causing an error on the registration page:

The constant was sometimes called 'GROUP_REGISTER_FIELD' and sometimes 'OG_REGISTER_FIELD'.

Fixing that, the error is gone and now I have the field 'group_register' which is set to 1 for two of my public groups.
But the groups still don't show up on registration page.

radoeka’s picture

Can the description be adjusted, as it states:
"As the title says "Organic Groups Register" does show."
It should be doesn't show.

Thanks

hoomanb’s picture

I wrote a module that does what I wanted OG to do, but just FYI this issue still exists.

amitaibu’s picture

Status: Active » Reviewed & tested by the community

@hoomanb,
> Since the field name didn't start with 'field_' I had to manually add it.

The field doesn't need to be prefixed with "field_" (only the ones you add via field UI are prefixed).

> The constant was sometimes called 'GROUP_REGISTER_FIELD' and sometimes 'OG_REGISTER_FIELD'.

Thanks, fixed on github -- https://github.com/amitaibu/og/commit/761af019ff2e4369bd736a4fece3aeb23d... (I'll mark fixed once synced with CVS).

Andrew M Riley’s picture

FileSize
510 bytes

Using the 7.x-1.x-dev it turns out the og_register_group_fields_info function should be called og_register_og_fields_info. Once I changed this I had the option to add the Groups Register line item in Group Field Settings.

amitaibu’s picture

Status: Reviewed & tested by the community » Fixed

Committed to Drupal.org (#5)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Matt B’s picture

Ok, need a little help here - I have og-register enabled. I cannot see an og-register field in the group content type settings or in the Group field settings? Where do I find it and enable it?

Matt B’s picture

Status: Closed (fixed) » Needs work
Matt B’s picture

Status: Needs work » Active

I've upgraded to the dev version, and now have the ability to add the registration field to the Group content type. I've selected 'Show on registration page' but there is no option on the registration page. og_register does not appear to work on either the 7.x-1.0 or 7.x.1.x-dev version.

amitaibu’s picture

Do you have og_field_access enabled?

Matt B’s picture

Yes

amitaibu’s picture

And did you check you have the permissions set correctly?

Matt B’s picture

As far as I can tell - I have non-members with the permission "Subscribe user to group". What are the correct permissions?

Matt B’s picture

I've now made sure "View Group type field" is ticked for non members and I get a Groups audience list on the registration form with the help text "Select the groups this content should be associated with." - not the most user friendly text for registration. I'll test registration tomorrow...

amitaibu’s picture

Status: Active » Fixed

> not the most user friendly text for registration.

I encourage you to write a patch to change it :)

Matt B’s picture

I'll look into it, the problem is that this is the same text used on the content forms, so presumably it's the same code and it wouldn't be a simple matter of changing a text string.

AndrzejG’s picture

I can't find og-register field, despite the module is enabled. Where is it?
The same for og_field_access.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

pfrenssen’s picture

I have been struggling with this too. I managed to get the groups to show up on the user registration form. Five ingredients are needed:

  1. Enable the og_register module.
  2. Go to admin/config/group/fields and add the Group register field to your group node entity.
  3. On the same page add the Groups audience field to the user entity.
  4. Edit each group entity you want enabled on the registration form, and enable the option Group register: show on registration page.
  5. Go to admin/config/people/accounts/fields/group_audience and check the option Show on registration form.

Good luck!

petednz’s picture

pfrenssen -thanks for those steps - not sure why 5/ was eluding me, possibly because the system had been originally configured without needing people to 'register' for group (as all groups were 'closed')

so yes those steps work - and as noted by Matt B - this results in the Groups field showing at user/register with "select the groups this content should be associated with"

and i wondered why this wasn't coming from the "help text' at /admin/config/people/accounts/fields/group_audience so i threw something in here, and hey presto the default msg of "Select the groups this content should be associated with" disappears and I just see my 'help text'

(but i continue to get "Select the groups this content should be associated with" for the field where it is used on Content Types, since this is per Field, of course).

So perhaps we just need a 6. on the above list namely

6. Add your own 'help text' at /admin/config/people/accounts/fields/group_audience in order to replace the default message of 'Select the groups this content should be associated with'

Thanks everyone

petednz’s picture

Issue summary: View changes

Fixed polarity of statement