0

I THINK my Contextual Filter from my view is not getting the correct NID from my URL.

I have a view page with a path of "node/%/agenda".

The link on my menu is "node/[node:nid]/agenda".

The view page will get the nid from a content type "Venue". Example: Venue: Rave = NID: 101 View page will be = "node/101/agenda"

I have a working block of "Upcoming Events" and this works perfectly fine on my venue content type. But when I use it on a view page it's not working anymore. Basically this block shows the "Upcoming Events" from "Event" content type that is related to the "Venue" content type.

BLOCK: enter image description here Setting: enter image description here

How it works on content type venue: enter image description here This is the wrong part: enter image description here

As you can see it does not get the same result on the view page, it does not even show the "No Result". I am calling the correct block.

Am I missing something big? I hope someone can help!

THANK YOU VERY MUCH!! ^_^

  • You didn't post the settings of the most relevant part of the view, the contextual filter. – rooby Nov 17 '14 at 5:32
  • Sorry, I edited it now, posted the setting – Danz Nov 17 '14 at 5:35
  • Are you 100% sure that the block is configured to show on that page? Default value Content ID from URL should work unless you have some specific validation rules for the contextual filter that aren't being met. – rooby Nov 17 '14 at 6:20
  • Yes, I did not put any other specific validation rules. Just the content ID from URL. If I try to remove the contextual filter then everything will show, if I put it back, it shows the blank div. there's a no result behavior but that's not showing on the page. – Danz Nov 17 '14 at 7:23
  • did you tried to connect events with the venue in RELATIONSHIPS ? – AlexB Apr 16 at 12:04
0

According to what i can see from the screen shots, you didn't specify your relationship entity on advanced menu. If I were you, I would pick a entity reference, then i would pick a content contextual filters with Nid. Otherwise there is no way that block is gonna understand what the relationship is. Please update us your work. This is a very sensitive topic of drupal. Kind regards

-1

Block displays have no source of arguments at all; they cannot pull arguments from the URL so Create a content pane instead of block in the view and in the "argument input" add the argument number.

  • This is not true. There are ways to use arguments with block views. – rooby Nov 17 '14 at 6:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.