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) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • event registration: change label of "continue" button
Pages: [1]

Author Topic: event registration: change label of "continue" button  (Read 804 times)

TwoMice

  • I post frequently
  • ***
  • Posts: 214
  • Karma: 16
    • Emphanos
  • CiviCRM version: Always current stable version
  • CMS version: Drupal 7
event registration: change label of "continue" button
September 12, 2010, 08:54:07 am
Hi,

In CiviCRM 3.1.3, I'd like to conditionally change the label of the "Continue" button that's at the bottom of the registration confirmation page ("CRM_Event_Form_Registration_Confirm"). 

At the moment I'm using hook_civicrm_buildForm() to change the label to "Continue to PayPal payment page >>", and this works well.  But if the user has selected the "pay later" option, that label is confusing and incorrect.  So what I'd like to do is to change the button label only when the user hasn't selected "pay later."

Can anyone suggest a way to do this?  I'm having trouble accessing the submitted "pay later" option value from within hook_civicrm_buildForm(), but it seems like that's really the right place to change the button label.  I could probably read "pay later" in hook_civicrm_postProcess(), but there's no way to change the button label in that hook.

Any ideas?

Thanks,
TM
Please consider contributing to help improve CiviCRM with the Make it Happen! initiative.

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: event registration: change label of "continue" button
September 12, 2010, 09:12:50 am
Hi,

Copy the template in your custom template folder, add a bit of jquery to change the label when checking/unchecking the paylater box, don't bother with the hook, life is too short.

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

TwoMice

  • I post frequently
  • ***
  • Posts: 214
  • Karma: 16
    • Emphanos
  • CiviCRM version: Always current stable version
  • CMS version: Drupal 7
Re: event registration: change label of "continue" button
September 12, 2010, 11:50:42 am
Just the advice I needed.  Glad I asked.  Thanks, X.
Please consider contributing to help improve CiviCRM with the Make it Happen! initiative.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • event registration: change label of "continue" button

This forum was archived on 2017-11-26.