• Resolved JK-WP

    (@jimmykavanagh)


    I found a piece of PHP code that allows me to hide the word “Free” on RSVP tickets. I have my site set to auto update all plugins and themes, which is the recommended setting for helping to keep your site secure. My theme just updated and overwrote functions.php, which meant the PHP code to hide “Free” was lost.

    Can you please add the ability to hide “Free” on RSVP tickets, via a tickbox in the admin user interface. This would prevent theme updates from killing the custom PHP code and help us to keep with best practice for site security.

    Loving the calendar plug in!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Abz

    (@abzlevelup)

    Hi @jimmykavanagh, thanks for providing more information here. Appreciate the kind words as well.

    Could you try this snippet here ??.

    function tribe_not_show_free ( $cost, $post_id, $with_currency_symbol ) {
     
        if ( $cost == 0 || $cost == 'Free' ) {
            $cost = str_replace('Free', '', $cost);
            $cost = str_replace(' – ', '', $cost);
        }
        return $cost;
    }
    add_filter ( 'tribe_get_cost', 'tribe_not_show_free', 10, 3 );

    You can install third-party plugin Code Snippets or directly add it to your functions.php file on your theme.

    See the article here for reference:
    https://theeventscalendar.com/knowledgebase/removing-free-from-event-cost-range/

    I’d recommend you try it out on a staging site first and always keep a working backup of your website to be safe.

    Hope that helps.

    Cheers,
    Abz

    Thread Starter JK-WP

    (@jimmykavanagh)

    Hi Abz,

    many thanks for the prompt response. As I mentioned in my original post, if I insert that code snippet in functions.php it breaks every time the theme is updated (I have auto update turned on to be compliant with best practice)

    I will investigate the Code Snippets add-in and see if that will help.

    But I would strongly suggest that he team consider adding a checkbox in the admin interface, as it means anyone could use the feature without resorting to php and reduce the need for other add-ins to get code snippets working.

    Regards.

    Plugin Support Darian

    (@d0153)

    Hi @jimmykavanagh

    Thanks for your response.

    I understand that you are looking for a specific feature and I want to help. To make sure that your request is heard, I recommend submitting it through this link: https://evnt.is/ideas.

    While I cannot guarantee a specific date for when this feature will be available, we truly appreciate and consider all ideas and contributions from our users. In fact, many of the ideas that receive the most votes from our customers are often included in our future releases.

    Let me know if you have further questions or concerns.

    Thread Starter JK-WP

    (@jimmykavanagh)

    Thanks Darian, appreciate your message . Will head over to the ideas area now.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Ability to hide “Free” on RSVP’ is closed to new replies.