Posted by kscott22 on August 10, 2010 at 6:37pm
I've got a site with the content type "event." I'd like users to be able to create a poll specific to a single "event" page. I'd like the poll to appear on the related "event" page and only that page. (So Poll A only appears at the bottom of the Event A page; Poll B only appears at the bottom of the Event B page; etc.)
Using CCK, I can have the user enter the URL of the event page when creating the poll. But how can I tell Drupal to post that poll on the bottom of that URL?
I'm sure this is possible -- I just can't seem to wrap my mind around it. Any suggestions or ideas would be very helpful! Thanks!
Comments
Panels can do that
Hi,
i've done a similar thing for a site for a political party: It has nodes of type "event" for events, and each event can be associated with one or more topics which are nodes of type "topic".
This functionality can be created using a combination of various modules. What I did is:
One problem is still unsolved: When creating a topic users still have to go to "Create Content -> Topic" and select an event from a potentially huge list of events which their topic should belong to. A solution for me was the prepopulate module - it allows to create links on events pages which link to a "Create Topic" page with the nodereference already selected accordingly.
I know it is a very complicated and roundabout way but it actually works well. See it in Action here:
https://www.piratenpartei-hamburg.de/termin/2010-08-10/piratentreffen
(in german language...)
Hope this helps, Gunnar
Thanks, Gunnar
I'll try this out and see how it goes. I really appreciate the quick reply!!!
Here's how I would approach
Here's how I would approach it...
Use CCK node reference to tie a poll to an event. You can even use the node reference URL widget to make it super easy to create the poll while viewing the event page so the user doesn't have to type anything in. Then use the views_attach module to create a view that displays the poll. Have that view take the event nid as an argument. The views_attach module will then display that view automatically on the event node page.
Since this is in the rules group... just an FYI that no rules are necessary.
-
@foggyperspectiv | foggyperspective.com (blog)
Node reference
Thanks! It appears that both of you are suggesting similar paths. I'm still a bit of a noob -- I haven't used Views arguments extensively and I've never used node reference before. I think the answer is there, but I'm still struggling due to my lack of experience.
I'm looking up tutorials on both arguments and node reference to help me out a bit -- if you have any suggestions of where I can go to educate myself, I'd be very appreciative.
Thanks again! I think you both have set me on the right path.
Node Reference (part of CCK)
edit: moved the discussion over to http://drupal.org/comment/reply/881792
-
@foggyperspectiv | foggyperspective.com (blog)