New Landing How can we help? Cardinal Masonry Blog Type Category Label

Viewing 15 posts - 1 through 15 (of 20 total)
  • Posted in: Cardinal
  • #114611
    astroluxxe
    Member
    Post count: 5

    On the Blog Shortcode / Masonry blog type

    When you see all the masonry post blocks, all of them have a label of “Article”. This “Article” label is not pulled from the Blog Category that the post belongs to. Even if an article belongs to blog category “White-Papers”, it still shows up as “Article”. How do I get it to show the correct category in this view?

    #114830
    Kyle – SUPPORT
    Moderator
    Post count: 35880

    Hi

    That label is for the post type, to remove it add this to your custom css:

    .masonry-items .details-wrap > h6 {
      display: none;
    }

    – Kyle

    #114845
    astroluxxe
    Member
    Post count: 5

    Is there a way to expose the category label then?

    #114846
    Kyle – SUPPORT
    Moderator
    Post count: 35880

    Not in that position no

    – Kyle

    #245873
    imweird
    Member
    Post count: 132

    Is there a Way to show Categories Lable in the masonry preview item? like this guy was asking..

    #245899
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    I am afraid that its not possible.
    Thanks
    Mohammad

    #245962
    imweird
    Member
    Post count: 132

    Then, is it possible to change the position of the elements?
    I would like to have the date on top before everything else, so Move the post-details (i’ve already hided everything else like author, likes etc.) on top of the Masonry item.

    #245977
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please provide me specific page url to check and find any solution.
    Thanks
    Mohammad

    #245978
    imweird
    Member
    Post count: 132
    This reply has been marked as private.
    #246001
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please paste this code at functions.php of child theme.

    function sf_get_masonry_post( $postID, $thumb_type, $fullwidth, $show_title, $show_excerpt, $show_details, $show_read_more, $content_output, $excerpt_length ) {
    			
    			global $sf_options;
    			
    			// Get Post Object
    			$post_object = sf_build_post_object( $postID , $content_output, $excerpt_length );
    			
    			// Link config			
                $post_links_match_thumb = false;
                if ( isset( $sf_options['post_links_match_thumb'] ) ) {
                	$post_links_match_thumb = $sf_options['post_links_match_thumb'];	
                }
                $post_permalink_config = 'href="' . $post_object['permalink'] . '" class="link-to-post"';
                if ( $post_links_match_thumb ) {
                	$link_config = sf_post_item_link();
                	$post_permalink_config = $link_config['config'];
                }
                
                // Variable setup
                $post_item = "";
                $comments_icon 	 = apply_filters( 'sf_comments_icon', '<i class="ss-chat"></i>' );
                $link_icon		 = apply_filters( 'sf_link_icon', '<i class="ss-link"></i>' );
                $sticky_icon   	 = apply_filters( 'sf_sticky_icon', '<i class="ss-bookmark"></i>' );
    
    if ( $show_details == "yes" ) {
                    $post_item .= sf_get_post_details($postID);
    }
                						
    			// THUMBNAIL MEDIA TYPE SETUP
    			$item_figure = "";
    			if ( $thumb_type != "none" ) {
    			    $item_figure .= sf_post_thumbnail( "masonry", $fullwidth );
    			}
                if ( $item_figure != "" ) {
                    $post_item .= $item_figure;
                }
    
    			// Open output
                $post_item .= '<div class="details-wrap">';
                $post_item .= '<a ' . $post_permalink_config . '></a>';
    			
    			// Title
                if ( $post_object['type'] == "post" ) {
                    if ( $post_object['format'] == "standard" ) {
                        $post_item .= '<h6>' . __( "Article", "swiftframework" ) . '</h6>';
                    } else {
                        $post_item .= '<h6>' . $post_object['format'] . '</h6>';
                    }
                } else {
                    $post_item .= '<h6>' . $post_object['type'] . '</h6>';
                }
                if ( $show_title == "yes" && $post_object['format'] != "quote" && $post_object['format'] != "link" ) {
                    $post_item .= '<h2 itemprop="name headline">' . $post_object['title'] . '</h2>';
                } else if ( $post_object['format'] == "quote" ) {
                    $post_item .= '<div class="quote-excerpt" itemprop="name headline">' . $post_object['excerpt'] . '</div>';
                } else if ( $post_object['format'] == "link" ) {
                    $post_item .= '<h3 itemprop="name headline">' . $post_object['title'] . '</h3>';
                }
    			
    			// Excerpt
                if ( $show_excerpt == "yes" && $post_object['format'] != "quote" ) {
                    $post_item .= '<div class="excerpt" itemprop="description">' . $post_object['excerpt'] . '</div>';
                }
                
    			// Details
                if ( $show_details == "yes" ) {
                    //$post_item .= sf_get_post_details($postID);
                    $post_item .= '<div class="comments-likes">';
                    if ( comments_open() ) {
                        $post_item .= '<div class="comments-wrapper"><a href="' . $post_object['permalink'] . '#comment-area">'.$comments_icon.'<span>' . $post_object['comments'] . '</span></a></div>';
                    }
    
                    if ( function_exists( 'lip_love_it_link' ) ) {
                        $post_item .= lip_love_it_link( $postID, false );
                    }
                    $post_item .= '</div>';
    
                }
    
    			// Close output
                $post_item .= '</div>';
    			               
    			// Return 
            	return $post_item;
            }

    Thanks
    Mohammad

    #246007
    imweird
    Member
    Post count: 132
    This reply has been marked as private.
    #246014
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please remove the last code and use this new code:-

    
    function sf_get_masonry_post( $postID, $thumb_type, $fullwidth, $show_title, $show_excerpt, $show_details, $show_read_more, $content_output, $excerpt_length ) {
    			
    			global $sf_options;
    			
    			// Get Post Object
    			$post_object = sf_build_post_object( $postID , $content_output, $excerpt_length );
    			
    			// Link config			
                $post_links_match_thumb = false;
                if ( isset( $sf_options['post_links_match_thumb'] ) ) {
                	$post_links_match_thumb = $sf_options['post_links_match_thumb'];	
                }
                $post_permalink_config = 'href="' . $post_object['permalink'] . '" class="link-to-post"';
                if ( $post_links_match_thumb ) {
                	$link_config = sf_post_item_link();
                	$post_permalink_config = $link_config['config'];
                }
                
                // Variable setup
                $post_item = "";
                $comments_icon 	 = apply_filters( 'sf_comments_icon', '<i class="ss-chat"></i>' );
                $link_icon		 = apply_filters( 'sf_link_icon', '<i class="ss-link"></i>' );
                $sticky_icon   	 = apply_filters( 'sf_sticky_icon', '<i class="ss-bookmark"></i>' );
    
                						
    			// THUMBNAIL MEDIA TYPE SETUP
    			$item_figure = "";
    			if ( $thumb_type != "none" ) {
    			    $item_figure .= sf_post_thumbnail( "masonry", $fullwidth );
    			}
                if ( $item_figure != "" ) {
                    $post_item .= $item_figure;
                }
    if ( $show_details == "yes" ) {
                    $post_item .= sf_get_post_details($postID);
    }
    			// Open output
                $post_item .= '<div class="details-wrap">';
                $post_item .= '<a ' . $post_permalink_config . '></a>';
    			
    			// Title
                if ( $post_object['type'] == "post" ) {
                    if ( $post_object['format'] == "standard" ) {
                        $post_item .= '<h6>' . __( "Article", "swiftframework" ) . '</h6>';
                    } else {
                        $post_item .= '<h6>' . $post_object['format'] . '</h6>';
                    }
                } else {
                    $post_item .= '<h6>' . $post_object['type'] . '</h6>';
                }
                if ( $show_title == "yes" && $post_object['format'] != "quote" && $post_object['format'] != "link" ) {
                    $post_item .= '<h2 itemprop="name headline">' . $post_object['title'] . '</h2>';
                } else if ( $post_object['format'] == "quote" ) {
                    $post_item .= '<div class="quote-excerpt" itemprop="name headline">' . $post_object['excerpt'] . '</div>';
                } else if ( $post_object['format'] == "link" ) {
                    $post_item .= '<h3 itemprop="name headline">' . $post_object['title'] . '</h3>';
                }
    			
    			// Excerpt
                if ( $show_excerpt == "yes" && $post_object['format'] != "quote" ) {
                    $post_item .= '<div class="excerpt" itemprop="description">' . $post_object['excerpt'] . '</div>';
                }
                
    			// Details
                if ( $show_details == "yes" ) {
                    //$post_item .= sf_get_post_details($postID);
                    $post_item .= '<div class="comments-likes">';
                    if ( comments_open() ) {
                        $post_item .= '<div class="comments-wrapper"><a href="' . $post_object['permalink'] . '#comment-area">'.$comments_icon.'<span>' . $post_object['comments'] . '</span></a></div>';
                    }
    
                    if ( function_exists( 'lip_love_it_link' ) ) {
                        $post_item .= lip_love_it_link( $postID, false );
                    }
                    $post_item .= '</div>';
    
                }
    
    			// Close output
                $post_item .= '</div>';
    			               
    			// Return 
            	return $post_item;
            }

    Thanks
    Mohammad

    #246021
    imweird
    Member
    Post count: 132
    This reply has been marked as private.
    #246028
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please provide me login detail after installing WPIDE plugin.
    Thanks
    Mohammad

    #246030
    imweird
    Member
    Post count: 132
    This reply has been marked as private.
Viewing 15 posts - 1 through 15 (of 20 total)

You must be logged in and have valid license to reply to this topic.

License required for one of the following items
Login and Registration Log in · Register