[Resolved] The Content Template 3 Column Not Workinh in Archives

Home Forums Support [Resolved] The Content Template 3 Column Not Workinh in Archives

Home Forums Support The Content Template 3 Column Not Workinh in Archives

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #2359061
    Chandan Prasad Sahoo

    I created a content template in Elements and it’s working fine for the home page. I also changed the Display posts in columns to 3 for archives but it’s not working. Please check the link below.
    https://usastorytime.com/web-stories/

    #2359257
    Ying
    Staff
    Customer Support

    Hi there,

    Is this a CPT archive?

    If so, the customizer option can not control it.

    You’ll need to add this filter to make it work:
    https://docs.generatepress.com/article/using-columns-in-the-blog/#adding-columns-to-your-custom-post-type

    #2359393
    Chandan Prasad Sahoo

    This is the Google web stories archive. I added this. But nothing changed.

    add_filter( 'generate_blog_columns', function( $columns ) {
        if ( 'web-stories' === get_post_type() && ! is_singular() ) {
            return true;
        }
    
        return $columns;
    } );
    #2359947
    Ying
    Staff
    Customer Support

    Is your CPT slug web-story or web-stories?

    Can you make sure it’s correct?

    #2360190
    Chandan Prasad Sahoo

    Thanks a lot. It was my mistake. That slug is web-story.

    #2360749
    Ying
    Staff
    Customer Support

    No worries!
    Glad it works now 🙂

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.