Score:0

How can I display a field from the current node?

br flag

How can I create a view block that displays a field from the current node?

It looks like there are contributed modules that provide this functionality, but it seems like it should be possible to achieve it with just the Views module and its contextual filters and relationships.

sonfd avatar
in flag
You just need to add a contextual filter for Content ID. And then have it get the value from the current page.
br flag
If I go to the Contextual Filters UI, and enter "nid" in the Search field, there is no ID option in the "Content" category. There is an option for "The node ID of the node" in the "Tracker" category, but this does not appear to be relevant. In other words, I see no way to create a contextual filter for Content ID.
br flag
Actually, it's working now. It works if I use "The node ID of the node" in the "Tracker" category. I was expecting to see an option for "The node ID of the node" in the "Content" category.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.