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) »
  • Developer Discussion »
  • APIs and Hooks (Moderator: Donald Lobo) »
  • billing field validation via hook_civicrm_validate ?
Pages: [1]

Author Topic: billing field validation via hook_civicrm_validate ?  (Read 964 times)

apotropaic

  • I post occasionally
  • **
  • Posts: 34
  • Karma: 1
  • CiviCRM version: 4.4.4
  • CMS version: Wordpress 1.8
  • MySQL version: 5.5.32
  • PHP version: 5.3.10
billing field validation via hook_civicrm_validate ?
December 30, 2010, 11:59:47 pm
I'm using hooks to implement discount codes successfully but have found an annoyance I'm trying to get around. Sometimes I have 100% discount codes that I had out to certain people each event, sometimes a membership level/group gets people 100% discounts. Is there ANY way in one of the hooks to bypass the billing fields being required? I've found it confuses/freaks people who know they have a 100% discount code and yet they are required to enter credit card info. Has anybody done this before? Thanks!

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: billing field validation via hook_civicrm_validate ?
December 31, 2010, 07:42:25 am

I think we dont do credit card checks if the amount is zero. You might want to double check and confirm this.

If so, you might want to adjust the templates to hide the credit card fields if the discount is 100%

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) »
  • Developer Discussion »
  • APIs and Hooks (Moderator: Donald Lobo) »
  • billing field validation via hook_civicrm_validate ?

This forum was archived on 2017-11-26.