Viewing 2 replies - 1 through 2 (of 2 total)
  • They have good hooks that let you overwrite these. I added the following to my functions.php to use the second category name as the kicker if the first category name is Instant Articles.

    function change_ia_kicker( $category_name, $post_ID ) {
    //Next block is my specific code
    	if ('Instant Articles' == $category_name) {
    		$categories = get_the_category($post_ID);
    
    		if ( is_array( $categories ) && count( $categories > 1) && isset( $categories[1]->name ) && __( 'Uncategorized' ) !== $categories[1]->name ) {
    			$category_name = $categories[1]->name;
    		}
    	}
    //At the end, return the new kicker
        return $category_name;
    }
    add_filter( 'instant_articles_cover_kicker', 'change_ia_kicker', 10, 3 );
    Thread Starter davert318

    (@davert318)

    Thanks. I looked for documentation but couldn’t find it. I’ll try adding a custom field somewhere and see if I can use that.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Tags -> Kicker: alternative?’ is closed to new replies.