To get the value of a node field first of all we need to get the node object.
So add the below code to your THEME_preprocess_node() function.
It is almost the same like in Drupal 7, but in Drupal 8 the concept changes as OOP.
So there are some difference to call the 'type'.
In my previous article we learned how to create a bootstrap subtheme in drupal 7.
In this article we can learn to create a bootstrap subtheme in Drupal8.
Power Cms Technology was formed to meet the growing demand for high-performance, cost-effective IT solution for their clients with the latest cutting edge technologies.
© Copyright 2016 by PowerCMS. All Rights Reserved.