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 CiviEvent (Moderator: Yashodha Chaku) »
  • CiviEvents error with Moneris payment processor
Pages: [1]

Author Topic: CiviEvents error with Moneris payment processor  (Read 1684 times)

civiced

  • Guest
CiviEvents error with Moneris payment processor
January 28, 2008, 11:38:51 am
I'm running CiviCRM 1.9 in Drupal 5.5 on CentOS 4.5 and received the following error while attempting a payment using Moneris in test mode...

warning: Missing argument 2 for CRM_Core_Payment_Moneris::__construct(), called in ...sites/all/modules/civicrm/CRM/Event/Payment/Moneris.php on line 57 and defined in ...sites/all/modules/civicrm/CRM/Core/Payment/Moneris.php on line 50.

Please correct the following errors in the form fields below:

    * Store ID is not set in the Administer CiviCRM » Payment Processor.

      Password is not set in the Administer CiviCRM » Payment Processor.

Settings are below:

Administer CiviCRM | Global Settings | Settings - Payment Processor

Processor Details for Test Payments

User Name: demouser
Password: yesguy
Store ID: store2
Site URL: https://esqa.moneris.com/gateway2/servlet/MpgRequest
Recurring Payments URL: [blank]

Why are the Store ID and Password values not getting through?

civiced

  • Guest
Re: CiviEvents error with Moneris payment processor
January 28, 2008, 11:50:18 am
Sorry guys, wrong forum thread. :-O

Deepak Srivastava

  • Ask me questions
  • ****
  • Posts: 677
  • Karma: 65
Re: CiviEvents error with Moneris payment processor
January 28, 2008, 11:24:52 pm
We did a check on it and found it's a valid bug.

We have fixed this for 2.0.

Here is the fix for 1.9 :

In the file CRM/Event/Payment/Moneris.php

Replace the fllowing line (56-58):
Code: [Select]
    function __construct( $mode ) {
        parent::__construct( $mode );
    }

With :
Code: [Select]
    function __construct( $mode , &$paymentProcessor ) {
        parent::__construct( $mode , $paymentProcessor );
    }

And the following line (69-74):
Code: [Select]
    static function &singleton( $mode ) {
        if (self::$_singleton === null ) {
            self::$_singleton =& new CRM_Event_Payment_Moneris( $mode );
        }
        return self::$_singleton;
    }

With:
Code: [Select]
    static function &singleton( $mode, &$paymentProcessor ) {
        if (self::$_singleton === null ) {
            self::$_singleton =& new CRM_Event_Payment_Moneris( $mode, $paymentProcessor );
        }
        return self::$_singleton;
    }

Let us know if this solves your problem.

Thanks.
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

civiced

  • Guest
Re: CiviEvents error with Moneris payment processor
January 29, 2008, 09:44:49 am
Hi deepak,

Thanks for the quick response.  Now I'm getting the following error before I even get to the CiviContribute form...

Sorry. A non-recoverable error has occurred.

This profile is not configured for the requested action. Contact the site administrator if you need assistance.

backTrace

...sites/all/modules/civicrm/CRM/Core/Error.php, backtrace, 255
...sites/all/modules/civicrm/CRM/Core/BAO/UFGroup.php, fatal, 383
...sites/all/modules/civicrm/CRM/Event/Form/Registration.php, getFields, 395
...

civiced

  • Guest
Re: CiviEvents error with Moneris payment processor
January 29, 2008, 10:18:03 am
Sorry deepak, I logged in as admin and it worked.  That leads me to another question though... shouldn't it display at least a permission denied error for anonymous users instead of a backtrace?

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • CiviEvents error with Moneris payment processor

This forum was archived on 2017-11-26.