i want to add a block to the sidebar that will display any related nodes of a particular content type, in this case "video". i have created a view which shows all videos, and successfully put it in a block (i know, big deal) and now for the hard part. how to get it to only show the videos which share the same term id with the page the user is looking at.
for instance, if there's a page called "sharkbait", and sharkbait is also a term with the id 45, i want only videos tagged with "sharkbait" to show up on that page's sidebar. and then if they're looking at the "hockeypuck" page, only videos with tagged with "hockeypuck". you get the idea.
i've tried using a php block without any luck, but it seems like views is so close, i'm hoping i can make it work.
would it be possible, using arguments or argment handling code, to filter these out? i'm not good at writing php, but i can understand most of it when i read it.
any ideas? thanks!
Comments
Comment #1
dawehneryou have to do this using views arguments handling code
Add a argument tid and set this in the argument handling code
Comment #2
esmerel commentedSuggested fix made.
Comment #3
jcharlesberry commentedIsn't there a way to do this using Views and Panels instead of using raw PHP?