• tried to modify the filter of the grid plugin, and it always shows Read Time: < 1 minute

    any possibility i can implement this to another plugin?

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter Gil Concepcion Jr.

    (@gilconcepcionjr)

    $output = $tg_el->get_media_wrapper_start();
    	$output .= $tg_el->get_media();
    	$output .= $tg_el->get_overlay();
    	$output .= $tg_el->get_center_wrapper_start();	
    		$output .= ($link_button && $media_button) ? '<a class="tg-item-link" href="'.$permalink .'" target="'.$target.'"></a>' : null;
    		$output .= $media_button;
    		$output .= $link_button;
    	$output .= $tg_el->get_center_wrapper_end();
    $output .= $tg_el->get_media_wrapper_end();
    $output .= $tg_el->get_content_wrapper_start();
    	$output .= $tg_el->get_the_title();	
        $output .= $tg_el->get_the_date();       
       $output .= $tg_el->get_the_terms($terms_args);
       $output .= do_shortcode ("[rt_reading_time label='Read Time:' postfix='minutes' postfix_singular='minute']");
        $output .= $tg_el->get_content_wrapper_end();	
    		
    return $output;
    Plugin Author Jason Yingling

    (@yingling017)

    You’ll probably need to pass the post id for the post the grid is displaying in the post_id parameter of the Reading Time shortcode.

    Thread Starter Gil Concepcion Jr.

    (@gilconcepcionjr)

    Hi Jason my issue with post_id will be all items listed in the grid will have the same minutes

    Plugin Author Jason Yingling

    (@yingling017)

    You need to pass the post_id of the post the grid item links to. So you’d get the post_id of the element similar to how you’re getting the title with $tg_el->get_the_title().

    That should have Reading Time calculate based off the content of the post ID you passed. Rather than the ID of page you display the grid on.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘working with the GRID Plugin’ is closed to new replies.