4

We have a free event that has several sessions with a max participant limit of 15. I've set that up with price sets with $0.00 amounts. It works fine, but because price sets are designed for paid events, there's a bunch of work to hide the pricing information from the user (css to hide the amounts on the registration, confirmation and thank you pages, modify the confirmation email to hide the payment sections and write a hook so Civi doesn't add the $0 contribution which is added, or tell folks to ignore those $0 contributions and delete them at some point.)

Just wanted to make sure there isn't a better way to do this. Any suggestions would be welcome.

2 Answers 2

3

I assume you're using price sets because you want to allow people to register for multiple sessions on a single event page? Have you checked out cart-style event registration? It's not maintained by core, but there seems to be a steady flow of people who ask questions about it, so it seems like it's getting use.

With cart-style event registration, each session is its own event, and you can dispense with price sets.

Finally - you did some amazing work on getting price sets to fit your use case! If you could publish your work somewhere, that would surely benefit someone.

7
  • Hey Jon - I was using price sets because I needed the max_participants feature which is an option for price sets. I don't know any other way to do that except setting up 4 different events, which isn't very appealing, but based on what Coleman said, I'm going to explore the 4 separate events + webform option and decide between that and pricesets in the next day or so. Whichever I do I'll post back here.
    – ASav
    Commented Jul 15, 2015 at 15:19
  • I ended up going to with the price sets approach because I have some other custom code that is based on profiles, so webform is too big a change for me right now. THere were some other minor issues with the webform approach - first off, we needed a radio button (select one) not check box (select many). Also I didn't like the way full the "full" message is at the top rather than next to the event. But those were minor. Big issue was the custom code.
    – ASav
    Commented Jul 16, 2015 at 14:52
  • So here's what I did:
    – ASav
    Commented Jul 16, 2015 at 14:52
  • 2
    I'm feeling like I went the long way around here. There must be an easier way, but this is working and you asked, so here 'tis: Set up a price set with $0 cost options, and set up an event using that price set. Modify (CRM/Event/Form/Registration|Register.tpl, ThankYou.tpl and Confirm.tpl) to allow you to know style the only for your event by adding something like crm-event-form-{$event.id} as a class to the crm-block div. (Obviously you aren't going to hack core, right?) Now style to your hearts content with liberal use of display:none to hide all the $ related stuff.
    – ASav
    Commented Jul 16, 2015 at 15:11
  • 2
    Then edit the message template "Events - Registration Confirmation and Receipt (on-line)" using {if $event.id=#} and {if $event.id neq #} to modify the confirmation email to hide fees in your special case. Lastly, in my case I had to deal with the validatepriceset code here: /CRM/Event/Form|Registration.php because if the user failed to select an option I got both the "you left this field blank" and the "Select at least one option from Event Fee(s)" errors so I hid the "Event Fee(s)" language for this event.
    – ASav
    Commented Jul 16, 2015 at 15:11
2

If you're using Drupal as your CMS, then yes, the simpler solution is to set up a CiviCRM Webform that allows people to register for one or more session (assuming that you have set up each session as a sep event).

Sorry, this won't work in WP or Joomla.

1
  • Thanks. Will take a look at that. Right now it's one event with a price set, but will consider webform and decide.
    – ASav
    Commented Jul 15, 2015 at 15:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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