Display node count by content type using Drupal views in 5 steps

xaiwant

December 1, 2014

Banner for Display node count

In previous post we have used Drupal views to create block displaying node count values for taxonomy terms. Now I am going to show how we can configure similar block to count number of nodes by content type.

  1. Add  “Content: Type (type) under Fields Section.
    Add  Content: Type (type) under Fields Section
  2. Configure field: Content: Type.

Configure field: Content: Type
 

  1. Under Contextual Filter add context “Content: Type”
    Under Contextual Filter add context “Content: Type”
     
  2. Configure contextual filter: Content: Type.
    By Selecting Display a Summary  under “When the filter value is NOT available”. By default option was checked for “Display record count with link” & Apply changes.
    Configure contextual filter: Content: Type

    Now the preview should have started showing up.
    Preview node count
     
  3. Saved Configuration to Apply Changes. You are done!

    Now just assign view block to specific region. 

Let’s team up and unlock amazing possibilities!