One block works, one doesnt

muckermarc - April 22, 2009 - 19:05
Project:Relevant Content
Version:6.x-1.4
Component:Miscellaneous
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

Hi,

I have 2 custom content types:
- "Show Page"
- "Presenter Page"

I have a taxonomy vocabulary "Shows-Presenters" which links the two content types together using tags. This taxonomy is working fine, as I can see the tags displayed on the relevant Show/Presenter pages.

I created 2 relevant content blocks as follows:
- "pres_show" Enabled on "Show Page", using vocabulary "Shows-Presenters", max of 5 items
- "show_pres" Enabled on "Presenter Page", using vocabulary "Shows-Presenters", max of 5 items

I add the 2 blocks to the same region, and set "pres_show" to only be displayed under URLs "presenters/*", and "show_pres" to only be displayed under "shows/*".

However, of the 2 blocks, only the "pres_show" block is displayed correctly on the Presenter pages - the "show_pres" block doesn't show up at all.

Cheers,

Marc

#1

nicholasThompson - April 22, 2009 - 19:37

Hmm... Interesting idea.

As a suggestion - may I point you towards using the modules Node Reference and Node Referrer.

Node Reference allows you to define a CCK Field which allows you to "reference" other nodes (filtered by type or "view result" I believe). You can then chose to display these as links on the node view.

Node Referrer is a "read only" CCK Field which will produce a set of links to nodes which are REFERENCING the current node.

Using this you could have your shows REFERENCE the presenters (and link to them on the node). On the presenter page, you can use node referrer to list all the shows which REFERENCE the presenter.

I use it to good effect on a Dark Basic Pro Challenges website...
http://challenges.dbp-site.com/challenges/overhead-shooter

In this case, a challenge is a node type and an entry is a node type. Each entry uses node reference to link it to a challenge. Each challenge uses node referrer to list all the entries associated with it.

Hope this helps :)

Nick

#2

muckermarc - April 22, 2009 - 19:55

Hi Nick,

Thanks for the tips - I did look at CCK and Node Reference, but could only see how to make it a one-to-one relationship, whereas I need a many-to-many relationship - in other words, a show might have multiple presenters, and a presenter may have multiple shows.

That's how I hit upon using taxonomy and Relevant Content.

But I'll look again at Node Reference.

Cheers,

Marc

#3

nicholasThompson - April 22, 2009 - 19:59

I'm fairly sure that Node Reference CCK fields allow you to define a field as having multiple entries...

#4

muckermarc - April 25, 2009 - 09:59
Status:active» closed

Hi Nicholas,
Many thanks for your help, node reference does allow multiple - I must have missed that setting.
Cheers,
Marc

 
 

Drupal is a registered trademark of Dries Buytaert.