Home Forums Event Espresso Premium Members only tickets Reply To: Members only tickets

Reply To: Members only tickets

Author Replies
Oguzhan Altun # Posted on May 10, 2018 at 2:36 am

Ok, so will the member ticket always be a replacement for the ticket without a capability set on it?

Will logged in users always have access to the member tickets or can they be logged in an not have access to specific member tickets?

Important distinction here is the members are not all logged in users. The members are logged in users who bought membership => they have um_member capability set by ultimate members plugin.

So yes, for these members, the members only ticket with 15% discount will always be a replacement vs normal ticket.

I’m asking because you set both tickets to be required and then use this snippet:

That’s a mistake, both tickets should not be required obviously

So if you have 2 tickets, one without a capability (we’ll callit ‘No cap ticket’) set and another with a capability set (we’ll call that ‘Cap ticket’) logged out users see both tickets, ‘No cap ticket’ will be required, Cap ticket will show the ‘no access’ message (doesn’t matter that its required when you can’t access it).

Correct. ‘No cap ticket’ with the no access message should show for both logged out users and for logged in users without ‘um-member’ capability.

Logged in users will only see the ‘Cap ticket’ as it has a capability set.

Correct. They could also see the no cap ticket (to understand that they’re getting the discounted ticket), but it should be greyed out. Another solution would be to show them just one ticket, but the original price crossed out and showing the 15% discounted price.

The snippet skips this functionality within the admin AND also shows ALL tickets if the user account has the ‘manage_options’ capability (meaning they are an administrator).

yes you’re right. I guess for the admin it can show both selected as zero tickets, so that we can do quick tests.

Do NOT follow this link or you will be banned from the site!