This project is not covered by Drupal’s security advisory policy.

example field with markup

This module has two (2) features:

  1. better UI selection of terms. concept of the UI is similar to Hierarchical Select module.
  2. creates related content block using the terms selected (that's why the name).

Better UI for selecting vocabularies

The module allows you to select multiple vocabularies in a single field entity. In Hierarchical Select, you can only choose 1 vocabulary at a time. It still synced the terms selected in the taxonomy table so you can still use this in views.

You can install this module just for this use.

Related Content Block

This module produce a block that displays related content using terms. The logic is different from other similar modules (see related modules) when generating the results. This is for specific use case where in the terms assignment are properly designed by the editors or site owner. It takes into consideration the hierarchy of the tags and the order of the group they are selected.

To better explain, here is an example. Let's assume we have Color as our only vocabulary assigned to a field entity. It has the following terms (written with hierarchy).

    # Red
      ## Light Red
      #### Light Red Combo 1
      #### Light Red Combo 2
      ## Dark Red
      ### Dark Red Combo 1
      ### Dark Red Combo 2
      ## Shiny Red
    # Blue
      ## Sky Blue
      #### Sky Blue Combo 1
      #### Sky Blue Combo 2
      ## Dark Blue
      ## Midnight Blue
    # Green
      ## Light Green
      #### Light Green Combo 1
      #### Light Green Combo 2
      ## Apple Green
      ## Dark Green

So let's say we have the following articles with term assignments (note the order of how they are selected and grouped):

  • Article1 are assigned the following terms:
    • Red » Light Red » Light Red Combo 2 // This is called group 1
    • Green » Light Green » Light Green Combo 1 // This is group 2
  • Article2 are assigned the following terms:
    • Red » Light Red // Group 1
    • Red » Dark Red // Group 2.
  • Article3 are assigned the following terms:
    • Red » Light Red » Light Red Combo 2
    • Green » Light Green » Light Green Combo 1
  • Article4 are assigned the following terms:
    • Red » Light Red
    • Green » Dark Green
  • Article5 are assigned the following terms:
    • Red » Light Red
    • Green » Light Green » Light Green Combo 1
  • Article6 are assigned the following terms:
    • Blue » Light Blue
    • Red » Dark Red » Dark Red Combo 1

If you are visiting Article1 and we only want to generate the top 3 related nodes, the following nodes will be displayed (in order)

  1. Article3
  2. Article4
  3. Article5

Why? Here is how they were selected:

  1. The search will start by looking for related contents marked in Group 1 only. It will start looking for nodes marked with "Red" and there are 6 articles.
    // Result: All
  2. From this 6 articles, it will find nodes tagged "Light Red". There are 5 nodes marked "Light Red".
    // Result: Articles # 1,2,3,4,5
  3. From this 5 articles, it will find nodes tagged "Light Red Combo 2". There is only 1 node - Article 3. So this article is our #1 Related node.
  4. Since we need to find 2 more, it will continue the search by going down Group 2.
  5. From the 4 nodes from Step 2 (minus the selected Article3), it will search for nodes that are tagged with "Green". There are 2 nodes only
    // Result: Articles # 4,5
  6. Since there are only 2 nodes, that completes the search for the top 3. If there are more than 2, then it will continue to search for nodes tagged "Light Green" then "Light Green Combo 1"

The first group dictates the overall relatedness of the nodes. This is only applicable if your content are well structured using taxonomy.

This is sponsored by Summit Media Group and Promet Source.

Other modules that creates related content:
See this document

How to Install/Setup

See README.txt

Project Information

Downloads