Support

Home Forums Event Espresso Premium Add "ticketing fee" or similar but on #checkout page (not in ticket selector)

Add "ticketing fee" or similar but on #checkout page (not in ticket selector)

Posted: September 13, 2016 at 8:30 pm

Viewing 4 reply threads


Adam Bowie

September 13, 2016 at 8:30 pm

I came across this thread https://eventespresso.com/topic/how-to-add-fee-to-all-ticket-sales/

Wanted to see if there is a way to add a ticketing fee, but not until someone begins the registration/payment process. Currently, by adding a price modifier, the surcharge is added to the price that shows in the ticket selector.

Is there a way to get the fee to first show up once registration has begun, as is common with Ticketmaster/Fandango, etc?

Thanks for the help,
Adam


Josh

  • Support Staff

September 14, 2016 at 9:32 am

Hi Adam, do you want to add a per ticket fee or a per transaction fee?


Adam Bowie

September 14, 2016 at 9:07 pm

Really, a per ticket fee…but it could also simply be a “per transaction” fee, but we can set it as a flat percentage, then it is really the same thing. (e.g. 3% ticketing fee would add 3% to each ticket…or 3% to the final amount at checkout).

Did I explain that well? Whatever is the simplest way to set it up is fine…we just want the amount to show only on the checkout page..not on the ticket selector box. Also, would want it not to apply on free tickets (which I do not think it would if it were a % amount).

Thanks for the help,
Adam


Josh

  • Support Staff

September 15, 2016 at 9:46 am

Hi Adam,

In that case what you would do is add the surcharge using the Ticket Editor UI, then use a filter hook to change how the price is displayed in the ticket selector. This is an example of the code you can use to display the base price of the ticket, instead of the ticket price + surcharge that’s normally displayed there:


add_filter( 'FHEE__ticket_selector_chart_template__ticket_price', 'change_ee_ticket_selector_base_price_display', 10, 2 );
function change_ee_ticket_selector_base_price_display( $ticket_price, $ticket ) {
    if ( $ticket instanceof EE_Ticket ) {
        if ( $ticket->base_price() instanceof EE_Price ) {
            $ticket_price = $ticket->base_price()->get( 'PRC_amount' );
        }
        return $ticket_price;
    } else { 
        return $ticket_price;
    }
}

You can add the above to a functions plugin or into your WordPress theme’s functions.php file.


Adam Bowie

September 15, 2016 at 12:23 pm

Great, we will implement this today and report back. Appreciate the help. I have said it many times, but your support is fantastic.

Viewing 4 reply threads

The support post ‘Add "ticketing fee" or similar but on #checkout page (not in ticket selector)’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso