[Support request] Adjusting archive page options with WPML string translations

Home Forums Support [Support request] Adjusting archive page options with WPML string translations

Home Forums Support Adjusting archive page options with WPML string translations

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1873637
    Naomi

    Hello,
    the code below works with WPML on both category archive pages but stops working when I turn on WPML string translations. Does anyone know why this could be? With a little check I could see that the code does still get past the first “if” but then the options aren’t applied. Has anyone else had this? Any suggestions welcome.

    add_filter( 'option_generate_blog_settings', 'bw_custom_archive_page_settings' );
    function bw_custom_archive_page_settings( $options ) {
    	if ( is_category( array( 8, 9 ) ) ) {
    		$options['post_image_alignment'] = 'post-image-aligned-left';
    		$options['post_image_size'] = 'medium';
    		$options['column_layout'] = false;
    		$options['featured_column'] = false;
    		$options['masonry'] = false;
    	}
    
        return $options;
    }
    #1874713
    David
    Staff
    Customer Support

    Hi there,

    WPML is not my strong suit unfortunately. If the condition is working then i can only assume that String Translation is affecting the strings in that code. Have you asked WPML as they may have had experience with this?

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