• Resolved Brian

    (@raceybe)


    Is there a hook available within the plugin that will prevent the presentation of the shortcode/buttons when a user is not logged in?

    For example, in my scenario, after processing the charge, I hook in and use the payment description to automatically grant voting tokens based on how they pay. However, this makes use of the current user id. I would want the shortcodes/buttons to not be visible if a user is not logged in.

    If this is not available now, is this something that could be added in the free/paid versions in the future? One option I suppose I could use now is adding a filter to the post content and searching for the shortcodes and removing them if a user isn’t logged in, but that would be a bit tricky I think.

    Thanks again for the great plugin. I’m considering the pro version because it is so easy to work with. I would hope the pro version maintains this ease of use.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Brian

    (@raceybe)

    So I used an add filter to modify the shortcode output if a user is not logged in (and replaced it with text about logging in). It is a little clunky, but it works. Still, an associate between the logged in account and making payments would be a very useful option.

    Any comment?

    Sounds like you did what we would have suggested – a custom solution.

    Not sure what we have on the roadmap as far as actually making that built into the plugin. But it is a great idea and I will mark it down for us to discuss.

    Thanks for the feedback.

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

The topic ‘Shortcode only when user logged in’ is closed to new replies.