Custom price ranges

Home Forums Calendar Products Filter Bar Custom price ranges

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1146152
    William
    Participant

    Hello! I have the same question as this one posted on July 11, but with all private replies. I’d like the price ranges to be more like 1-10, 11-25, 26-50, etc.

    • This topic was modified 7 years, 9 months ago by William.
    #1146171
    George
    Participant

    Hey William,

    Thanks for reaching out!

    That forum exchange touched on other issues, but in regards to the custom price ranges in Filter Bar, the gist of the conversation is that there is unfortunately no way to modify those price ranges without performing extensive code modifications to the Filter Bar plugin.

    We cannot help with such modifications, unfortunately, but we do have a list of great developers here if you’re interested in hiring someone to help you modify that code → http://m.tri.be/18k1 (and we have no affiliation with any of these folks–they’re simply some well-respected names in the community that we’ve compiled).

    If you yourself are comfortable diving into the code, then while I cannot help with writing the complete necessary code, I’m to help point you in the right direction for getting started here. Which would be to look for this filter within the Filter Bar plugin files:

    tribe_events_filter_values

    ☝️ You can write a filter callback that modifies the output of the values with that filter. To get started, you’d do something like this in your theme’s functions.php file:


    add_filter( 'tribe_events_filter_values', 'tribe_modify_the_price_range_filters', 10, 2 );

    function tribe_modify_the_price_range_filters( $values, $slug ) {

    print_r( $values );
    var_dump( $slug )

    return $values;
    }

    You’ll have to take the reins from there and tinker around, but I hope this information helps!

    Cheers,
    George

    #1147121
    William
    Participant

    Thanks!

    #1147692
    George
    Participant

    Sure thing! Be sure to make backups of all custom code so you minimize the risk of losing it and to give you some leeway in tinkering (because you have the original files to always revert back to).

    Best of luck with your project!
    George

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Custom price ranges’ is closed to new replies.