Posted: September 11, 2018 at 7:25 am
|
Hi, Some time ago, we used the following code
so that free events with a price of zero would display as “This is a free event/course” However, we are now in the process of setting up paid courses and we’re testing using PayPal Express sandbox. It looks like that code is displaying “This is a free event/course” whereever a balance of a paid for account is zero (i.e. payment has been made and approved). So far, we’ve seen this on the thankyou page, As well as on the receipts, invoices and payment confirmation email
As we’re offering both free and paid for courses, we want to be able to keep the “This is a free event/course” messages on free courses, but this shouldn’t show anywhere where a customer has paid. How can we get around this? Thanks Phil |
September 11, 2018 at 11:33 am Hi Phil, What you can do is make a slight adjustment to the code so it only alters the display if it’s a free event & it’s the page that shows the event information. For example this: |
|
|
September 11, 2018 at 12:07 pm Hi Josh, That tidies things up for the paid for courses, but now the free courses show £0.00 everywhere instead of “This is a free event/course” so I’ve had t revert the code. What I need to be able to do is display “This is a free event/course” if the course if free and display the prices and remaining values where the course is a paid for course. Regards Phil |
September 11, 2018 at 12:17 pm Hi Phil, It shouldn’t be an “everywhere” change as you suggest. The event page itself will still show “This is a free event/course”, within the ticket selector table. |
|
|
This reply has been marked as private. |
Hi Phil, There are some limits to what you can do with that filter, but a different approach would be to add a check for any front-end WordPress page. e.g. change the conditional to be: |
|
|
September 12, 2018 at 12:46 am Hi Josh, Thanks. That’s almost perfect. Almost 🙂 is there any way we can either a) disable invoices and receipts on free courses, where ticket price is zero or without upsetting the normal flow for paid for courses? With thanks Regards Phil |
|
September 12, 2018 at 12:53 am Hi Josh, Sorry, just noticed the Event Payment Details email also still shows Amount Due: This is a free event/course Is there a way to correct that so we show zero on paid for courses and “This is a free event/course” on free ones? Thanks Phil |
Are you sure that email was generated while the With regards to Receipts, Invoices & Free events, what you could do is remove the link to the Invoice from the Receipt (go to Event Espresso > Messages > Default Message Templates and end the Receipt template) You’ll remove the [INVOICE_RECEIPT_SWITCHER_BUTTON] shortcode from that template. When someone registers for a free event they wouldn’t normally receive an invoice, unless they happened to click on the invoice button from the Receipt. |
|
|
Hi Josh, I checked the code, flushed all caches and ran another test transaction and the Event Payment Details email still shows: We’re just notifying you of a successful payment made for the following transaction and tickets: Payment Details: Payment Status: Complete Ticket Name: Me In Mind The code is as follows (I’ve commented out the two previous conditionals)
Regards Phil |
You could try changing the code to the following:
Which is a more precise conditional. |
|
|
Thanks Josh. That worked 🙂 With regards to invoices and receipts, is it possible to make the display and/or generation of those conditional on whether the course or event is free or not? With thanks Regards Phil |
Hi Phil, What you can do is set up a custom receipt template that does not include a link to download an invoice, then assign that receipt template to all the free events. This is set within the event’s “Notifications” meta box. |
|
|
Thanks Josh. I’ll check that out this afternoon. Thanks for all your help with this. Outstanding support as always. Cheers Phil |
The support post ‘Mixing Free Events and Paid Events’ 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.