• Hello,

    First of all, thanks for making Team Showcase! It’s a great plugin. I found a compatibility with some other plugins when I am using the lightbox option on the team page, and I have an easy fix to recommend. (I tried submitting this on https://www.themepoints.com/contact/, but got a server error.)

    The lightbox tries to get content from the individual team member page using the selector .tscontent, but that class actually appears in many places on the target page when other plugins are inserting content from custom post types (in my case a site-wide notification and some mega menu blocks). I noticed in tshowcase.php that the html for the team member is added via add_filter( 'the_content', 'tshowcase_member_page' ). Unfortunately, content from those other plugins is also getting filtered and wrapped with the Team Showcase markup, including the tscontent class. That means that the lightbox on the main Team Showcase page pulls in all kinds of random stuff instead of just the actual team member info.

    I fixed the issue by adding the following conditional statement at the top of the function declaration for tshowcase_member_page:

    // Single Member Page Check
    function tshowcase_member_page( $content ) {
    	if(!is_singular() || !in_the_loop() || !is_main_query()){
    		return $content;
    	}

    That will cause anything on the team member page other than the main content to be returned unfiltered. The team member content will still be filtered like normal, and the lightbox will only retrieve the intended content.

    I hope that is useful information. Keep up the great work!

    Thank you,
    Reed

  • The topic ‘Quick fix for compatibility with other plugins’ is closed to new replies.