Skip to:

Making content public within a hidden group

  • Toby


    Bit of a weird one here.

    I’m using a calendar plugin and a hidden group are using it quite extensively. However, they want to publish certain events publicly to a page.

    The calendar plugin uses url parsing to output the current calendar view (i.e. group/calendar/2014/12/ shows December 2014 etc.).

    I’m wondering if it’s possible to allow certain content to be public using a URL action (e.g. group/calendar/2014/12/published/) and then check a flag in the database so that only public events are outputted?

    $user_has_access = apply_filters_ref_array( ‘bp_group_user_has_access’, array( $user_has_access, &$no_access_args ) ); looks like the perfect candidate, but it seems to be called way before the plugin gets to parsing the URL. Also, when I tried setting it in functions.php I still got a 404 when trying to visit the page.

    Is it simply impossible to have public content from a hidden group?

Viewing 2 replies - 1 through 2 (of 2 total)

  • shanebp


    I don’t think you can make a public page in a hidden group.
    The viewer is either a member or they aren’t – and that applies to /group/…
    You could make a WP page and apply a template to it.
    That template could call a function that gathers public events.



    Thought that might be the case. I just thought it would be handy to have the calendar functionality in place.

    I was trying to add the calendar functionality to a custom page by calling the class, but the URL parsing doesn’t work outside of the group structure and I don’t really want to rewrite the whole plugin just for this.

    I’ll just do a custom page with a list of events for them.

    Thanks for getting back to me.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Making content public within a hidden group’ is closed to new replies.
Skip to toolbar