Strange Double Rendering with Thesis

Home Forums Calendar Products Events Calendar PRO Strange Double Rendering with Thesis

Viewing 15 posts - 16 through 30 (of 65 total)
  • Author
    Posts
  • #15878
    Nathan
    Member

    Thanks for the kind words about the site, Carlos. Fingers crossed for the ECP solution!

    #15907
    Ross
    Member

    I have also had problems when trying to select a page template for the Events plugin to render on. Someone let me know if you figure this out. I know Thesis and the newer WordPress updates have had their share of issues too so running all three together could produce some strange results.

    #15936
    Jonah
    Participant

    Hey Carlos, you can find the buttons in: /wp-content/plugins/the-events-calendar/views/gridview.php – remember, to override place a copy of the file in an ‘events’ folder in your theme. Does that help?

    I’m working on a solution to the full page layout dilemma right now…

    #15939
    Jonah
    Participant

    Alright guys, here is a way to conditionally display or not display your sidebars in Thesis. Add this to your custom_functions.php file:


    // Conditionally remove original sidebars
    function no_sidebars() {

    if('tribe_events' == get_post_type()) {
    if ( is_single() && !tribe_is_showing_all() ) { // single event
    return true;
    } elseif ( tribe_is_upcoming() || tribe_is_past() || tribe_is_day() || (is_single() && tribe_is_showing_all()) ) { // list view
    return true;
    } else { // grid view
    return false;
    }
    }

    }
    add_filter('thesis_show_sidebars', 'no_sidebars');

    If you want the sidebar to appear just set return true on.

    #15943
    Nathan
    Member

    Hmmm. This knocked out my sidebars on on other pages (home, about). Any ideas how to fix that?

    Also, had to set the page template (in admin->settings->the events calendar) to something other than “default events template” otherwise the calendar page displayed without loading the rest of the theme (if that makes sense) – just a bare text header, etc. This is not really a problem for me – I just set it to “default page type” and everything works fine. Just wanted to point it out for anyone else.

    #15957
    Jonah
    Participant

    Try this instead:


    // Conditionally remove original sidebars
    function no_sidebars() {

    if('tribe_events' == get_post_type()) {
    if ( is_single() && !tribe_is_showing_all() ) { // single event
    return true;
    } elseif ( tribe_is_upcoming() || tribe_is_past() || tribe_is_day() || (is_single() && tribe_is_showing_all()) ) { // list view
    return true;
    } else { // grid view
    return false;
    }
    } else {
    return true;
    }

    }
    add_filter('thesis_show_sidebars', 'no_sidebars');

    #15959
    Nathan
    Member

    that made my entire site go blank. Like staring into the abyss. Well, a white abyss, anyway.

    #15962
    Ross
    Member

    Unfortunately this didn’t work for me. Great function just not sure why it is not working for me. I don’t have any conflicting functions either.

    #15970
    Ross
    Member

    For now I am just using something like this on the Upcoming Events page.

    function no_sidebars() {
    if (!is_page( ‘Upcoming Events’ ))
    return false;
    else
    return true;
    }
    add_filter(‘thesis_show_sidebars’, ‘no_sidebars’);

    I also noticed Thesis does not add the proper css class to the body tag and it changes to every top show in the feed. So even removing the sidebars doesn’t expand the #content div in fixed width divs anyways and if you try to dictate that by the body css class then you will have to constantly update your css. Not sure why this is not taking this from the headline_area

    Let me know if anyone else gets this problem or maybe I have a conflict.

    #16033
    Nathan
    Member

    @Ross, tried that code and got a completely blank site. I’m not a coder (paint-by-numbers), but that does seem to be the right logic. I only want to remove sidebars from the calendar grid page. Ideally, I’d like to keep them on the single events, etc pages. So it would seem logical to have the else part of the function return true. I tried more or less the same function myself using is_page to specify the page by slug and then again by name. There’s no way to specify by ID, right? since the page is generated on the fly. I guess that probably wouldn’t make a difference, anyway.

    #16060
    Jonah
    Participant

    Hey Nathan/Ross,

    The second function I posted above should work, I tested in Thesis 1.8.3 so maybe you are using an older version that uses a different filter?

    @Nathan – in my function I first check to see if the tribe_events post type is present and wrap all the other conditional code in that so it should only operate on event related pages. And if the post type is not present, I use the else condition to default to returning true.

    Overall, it should work but make sure you are using the latest version of Thesis…

    #16085
    Carlos
    Participant

    Jonah tell the tri.be guys you need a raise!! You just made my day. The code works perfectly in Thesis 1.83 (better work when DIY finally releases V2) and ECP 2.04.

    Hey is it still possible to get in on the community plugin beta testing? I have gravity forms but if you guys have an in house plugin I’d rather go that route.
    Cheers!
    C

    #16090
    Nathan
    Member

    Jonah, I hope I didn’t make you pull any extra hairs out – the 2nd function above is working for me now. I am (and was) using 1.8.3, so I must have just made a mistake copying previously. I think I might have missed the last curly bracket in above the add_filter line (I almost missed it this time).

    Thanks – calendar looks great now!

    #16098
    Rob
    Member

    Carlos: shoot an email to pro /a/ tri.be, we may be able to hook you up.

    Nathan: excellent to hear you got this figured out. Sounds like we’re all set here, but please let me know if not.

    #16109
    Ross
    Member

    I was using Thesis 1.8.2 and upgraded to 1.8.3 and the function still did not work for me. Not sure what it is.

Viewing 15 posts - 16 through 30 (of 65 total)
  • The topic ‘Strange Double Rendering with Thesis’ is closed to new replies.