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 »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • Credit Card Contributions on behalf of Contacts, How to switch to Live?
Pages: [1]

Author Topic: Credit Card Contributions on behalf of Contacts, How to switch to Live?  (Read 2115 times)

civicpixel

  • I’m new here
  • *
  • Posts: 25
  • Karma: 3
Credit Card Contributions on behalf of Contacts, How to switch to Live?
October 16, 2007, 06:28:51 pm
The problem we are having is fairly simple: when I view a contact, click on the contributions tab and then click on "Submit Credit Card Contribution" I'm taken to the contribution form but it's always in Test mode. IE at top it displays: A TEST transaction will be submitted using the selected payment processor.

We're using Paypal Website Payments Pro and all of our custom contribution pages work properly in both LIVE and TEST mode, but I can't figure out how to set the mode for this default, 'on behalf of' contribution page. We're running on 1.8 at the moment. I checked the 1.9 demo site, and when you repeat the same process there it loads the contribution page up in Live mode. I'm probably missing a setting somewhere, has anyone else run into this problem or have any idea where I should look?

Thanks,
Brian

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: Credit Card Contributions on behalf of Contacts, How to switch to Live?
October 16, 2007, 06:34:21 pm

Brian:

1. What revision of 1.8?

2. Can u check the file: CRM/Contribute/Form/Offline.php

specifically line 67 or so, should be:

$this->_mode       = $this->_action & CRM_Core_Action::PREVIEW ? 'test' : 'live';


we've hacked the code in the past to make it in test mode all the time, since we use that mainly

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

civicpixel

  • I’m new here
  • *
  • Posts: 25
  • Karma: 3
Re: Credit Card Contributions on behalf of Contacts, How to switch to Live?
October 18, 2007, 01:28:06 pm
Hey Donald,

Thanks for the quick reply, we're on version 1.8.10954.

The line you pasted matches the line in our version of Offline.php:
 $this->_mode       = $this->_action & CRM_Core_Action::PREVIEW ? 'test' : 'live';

I actually tried fooling around with that line previously to see if I could force it to live, but it didn't seem to have any affect (i.e. setting $this ->_mode = 'live'; did not change the "A TEST transaction will be submitted" message on the contribution form.

Thanks!
Brian

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: Credit Card Contributions on behalf of Contacts, How to switch to Live?
October 18, 2007, 01:40:59 pm

Can u do a search in that file and check if there is a statement like:

$this->_mode = 'test';

(or just search for 'test')

If not, can u get on IRC and i can help debug

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

civicpixel

  • I’m new here
  • *
  • Posts: 25
  • Karma: 3
Re: Credit Card Contributions on behalf of Contacts, How to switch to Live?
October 18, 2007, 01:48:44 pm
Searched through the file for 'test', no other occurrences than line 67. I'll hop on #civicrm now.

Brian

civicpixel

  • I’m new here
  • *
  • Posts: 25
  • Karma: 3
Re: Credit Card Contributions on behalf of Contacts, How to switch to Live?
October 18, 2007, 02:12:57 pm
Thanks to Donald we've resolved this problem.

This issue seems to be confined to certain older revisions of 1.8 -- ours specifically was 1.8.10954. If anyone else is having the same issue you can either upgrade to the current revision of 1.8, or change line 58 of /CRM/Contribute/Form/Offline.php from:
Code: [Select]
$this, false, 'preview' );to:
Code: [Select]
$this, false, 'false' );
Thanks Donald,
Brian

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • Credit Card Contributions on behalf of Contacts, How to switch to Live?

This forum was archived on 2017-11-26.