CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Discussion (deprecated) »
  • Feature Requests and Suggestions (Moderator: Dave Greenberg) »
  • Age restriction for events
Pages: [1]

Author Topic: Age restriction for events  (Read 3030 times)

BarisArt

  • Guest
Age restriction for events
January 30, 2008, 05:13:24 am
It would be very nice if events - apart from max participants - have an age restriction.
For example:

We organize summercamps for different age groups. So one 'event' is a summercamp for children in the age of 7-9 years old, the other is for children in the age of 10-12 years old, and so on.

Would be nice to have an age setting for events and a d.o.b. field for event registrations :)


Baris

Kurund Jalmi

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4169
  • Karma: 128
    • CiviCRM
  • CiviCRM version: 4.x, future
  • CMS version: Drupal 7, Joomla 3.x
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Age restriction for events
January 30, 2008, 06:29:07 am
You will have do some custom coding for this. In 2.0 if have added validate hook which can handle this.
Please check http://issues.civicrm.org/jira/browse/CRM-2480

HTH

kurund
Found this reply helpful? Support CiviCRM

BarisArt

  • Guest
Re: Age restriction for events
February 23, 2008, 02:00:19 am
Hi Kurund,

thanks for the link. I applied the patch, but what would be my next step?
Where do I enter script to validate input fields?

I hoped that an textarea would appear where I could enter some code to do the validation (like the Drupal webform module by example), but it looks like I need to write a module?

Can you give me some hints where to look? I am new to CiviCRM.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Age restriction for events
February 23, 2008, 11:23:16 am

1. CiviCRM hooks are similar to Drupal hooks. You need to be familiar with how to write a drupal module and implement drupal hooks.

2. Check http://wiki.civicrm.org/confluence/display/CRMDOC/CiviCRM+hook+specification bottom section. I've added some documentation for the validate hook along with a very simple sample implementation.

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Discussion (deprecated) »
  • Feature Requests and Suggestions (Moderator: Dave Greenberg) »
  • Age restriction for events

This forum was archived on 2017-11-26.