Show nodes that reference a node, in a block
News content type has a nodereference that references Industries, Services, Products, and Testimonials.
From the Product, Testimonials, Services, and Industries nodes we should be able to see what News nodes referenced them.
That is, when on the product Widget, we want it to see news items that reference Widget.
Here is the answer to showing in a block the nodes that nodereference the current node
http://drupal.org/node/161867#comment-256061
arg(0) would be node, and arg(1) is the node ID.
From the below issues:
Note that relationships in Views 2 make this trivial as long as you're using a 'Field' row-style View :
Add a 'Node:id' argument, add a relationship on the noderef field, and add the node title (for instance) through the relationship.
You get the titles of the nodes referenced by the nid you provide as an argument.
list nodes referenced by a noderef field
Works fine using a Node:nid argument + noderef relationships
http://drupal.org/node/241078
"Giving it a quick try, it seems to work fine except for nodes for which the noderef field is empty (also generates a broken link in the summary). Thus keeping as 'code needs work'"
Let row plugins follow relationship
http://drupal.org/node/327366
It's like they were solving the problem while we typed.
Reference
http://amariotti.com/blog/reverse-nodereference-block
See Also
http://drupal.org/project/views_attach
Comments
Post new comment