• Resolved paprika27

    (@paprika27)


    TECFB contains li.tribe-events-category-$slug which I am trying to style exactly the same as all other styled classes.

    I have tried without success:

    adding

    $css[] = 'li.tribe-events-category-' . $slug . ',';

    in the plugin’s source files,

    adding

    echo apply_filters( 'teccc_fix_category_background_color', null, 'li.tribe-events-category-' . $slug );

    in the plugin’s source files,

    adding

    li.tribe-events-category-<?php echo $slug ?>,

    in the plugin’s view files,

    adding

    add_filter( 'teccc_fix_category_background_color', function( $empty, $cat_selector ) {
        return 'li.' . $cat_selector . ', ';
    }, 10, 2 );

    or

    add_filter( 'teccc_fix_category_background_color', function( $empty, $cat_selector ) {
        return 'li' . $cat_selector . ', ';
    }, 10, 2 );

    in my functions.php

    Please help!

    EDIT: one step further: I’m overriding category.css.php as per the wiki, including

    li.tribe-events-category-<?php echo $slug ?>,

    at the respective place. When I query ?debug_css, all looks as intended. When I don’t query or query ?refresh_css, the override shows no effect.

    • This topic was modified 6 years, 8 months ago by paprika27.
    • This topic was modified 6 years, 8 months ago by paprika27.
    • This topic was modified 6 years, 8 months ago by paprika27.
    • This topic was modified 6 years, 8 months ago by paprika27.
Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Andy Fragen

    (@afragen)

    I don’t currently have access to the FilterBar Add-on. Sometime in the past it did work with the FilterBar, but I’m certain I removed it as I couldn’t get consistent results.

    Using either ?debug_css or ?refresh_css should have the same effect. If you have page caching on that may be an issue.

    I’ll look into seeing if I can add a filter somewhere to be able to add CSS selectors. But that may take some time.

    Thread Starter paprika27

    (@paprika27)

    waiting a while fixed it. Apparently, refresh_css did not actually touch the cache but time did?

    there is no caching plugin installed, browser cache was cleared every try i gave it.

    Thanks!

    EDIT: I was too quick to conclude: in photo view, it now works without query. in month view I now see the same behavior: it works fine if i query debug, it does not, otherwise. I’ll wait awhile again but it sure is weird.

    • This reply was modified 6 years, 8 months ago by paprika27.
    • This reply was modified 6 years, 8 months ago by paprika27.
    • This reply was modified 6 years, 8 months ago by paprika27.
    Plugin Author Andy Fragen

    (@afragen)

    You might need to use the ?refresh_css in each view.

    Glad is all seems to be working.

    Plugin Author Andy Fragen

    (@afragen)

    Just out of curiosity, of the things you did, which one finally worked, the filters or a template override?

    Thread Starter paprika27

    (@paprika27)

    the template override was the only way in which I was able to get it working. I’m assuming I got the syntax wrong on the filters.

    EDIT: The behavior persists: refresh query or no query don’t seem to look at the override, debug works fine. Can you tell me where the cache

    set_transient( $cache_key, $css, 4 * WEEK_IN_SECONDS );

    would be located? i’d like to remove it manually.

    EDIT: Nevermind, reinstalling the plugin did it. now, without query, override is in effect as desired. I recommend adding this to your wiki as a customization example.

    • This reply was modified 6 years, 8 months ago by paprika27.
    • This reply was modified 6 years, 8 months ago by paprika27.
    Plugin Author Andy Fragen

    (@afragen)

    I’m pretty certain the wiki can be edited by anyone.

    Thread Starter paprika27

    (@paprika27)

    pagespeed was enabled. now it does what I expect.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Add Filterbar to scope’ is closed to new replies.