Home › Forums › Welcome! › Pre-Sales Questions › Remove "Free" from event list and event details
- This topic has 7 replies, 2 voices, and was last updated 8 years ago by
Steven Hampton.
-
AuthorPosts
-
February 16, 2018 at 2:12 pm #1455813
Steven Hampton
ParticipantI have several events that are free and the client would like to remove that wording both from the events list and individual event page.
I found this thread that was closed: https://theeventscalendar.com/support/forums/topic/how-do-you-remove-free-from-list-view-when-using-free-event-tickets-plugin/
I inserted the snippet from that thread into my functions.php and it removed the words Free, the button to click through to the event, and the price of events that were not free. I think that snippet needs a revision and I was hoping someone could provide it.
`/*
* The Events Calendar – Make code empty if it’s 0 or Free
*/
add_filter ( ‘tribe_get_cost’, ‘tribe_not_show_free’, 10, 3 );
function tribe_not_show_free ( $cost, $post_id, $with_currency_symbol ) {if ( $cost == 0 || $cost == 'Free' ) { $cost = ''; } return $cost;}`
February 19, 2018 at 10:07 am #1457743Jennifer
KeymasterHi Steve,
Thanks for reaching out! I’d be happy to help you with this.
Can you please send me a screenshot of the settings for the free ticket so that I can see how it is set up?
Thanks,
Jennifer
February 20, 2018 at 7:34 am #1458628Steven Hampton
ParticipantHere is the screenshot. Let me know if you need further details from this.
February 26, 2018 at 6:31 am #1463712Jennifer
KeymasterThanks! Try adding this snippet (minus the opening <?php tag) to the functions.php file of your child theme. Let me know if this works for you!
February 26, 2018 at 9:03 am #1463898Steven Hampton
ParticipantI added that snippet and it removed the price from the items that had a fee as well.
It’s the same trouble I had previously.
March 15, 2018 at 5:18 pm #1480758Jennifer
KeymasterHi Steven,
I’m so sorry for the delayed response here – this thread was not showing up as waiting on my end. I apologize about that!
Try adding this snippet instead. I tested this out in my local environment, and it is working on my end. Please let me know if this does what you are looking for!
Thanks,
Jennifer
April 6, 2018 at 9:35 am #1498821Support Droid
KeymasterHey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.
Thanks so much!
The Events Calendar Support Team -
AuthorPosts
- The topic ‘Remove "Free" from event list and event details’ is closed to new replies.
