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) »
  • Error with PayPal payment
Pages: 1 [2] 3

Author Topic: Error with PayPal payment  (Read 7723 times)

crispin

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
    • Crispin Read dot co dot UK
  • CiviCRM version: various
  • CMS version: Drupal
  • MySQL version: various
  • PHP version: various
Re: Error with PayPal payment
September 27, 2012, 03:31:27 am
Hi Deepak - I replaced register.php with the file in SVN but still getting this error choosing any payment but pay later

The error also appears if a user tries to amend any payments

I'm afraid I don't know how to find the value of $this->_feeBlock but rather than send you a db dump I can direct you to the dev site if you want to take a look?

http://civicrm4.saltlight.org/civicrm/event/register?reset=1&id=25
login: demo demo
Say hello on Twitter: @crispin_read

crispin

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
    • Crispin Read dot co dot UK
  • CiviCRM version: various
  • CMS version: Drupal
  • MySQL version: various
  • PHP version: various
Re: Error with PayPal payment
September 28, 2012, 09:04:40 am
Just subscribing to the thread...
Say hello on Twitter: @crispin_read

Deepak Srivastava

  • Ask me questions
  • ****
  • Posts: 677
  • Karma: 65
Re: Error with PayPal payment
October 01, 2012, 05:08:42 am
Crispin, I'm assuming you know 4.2.2 is out, you will check & report back.
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

jdaniluk

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
  • CiviCRM version: 4.2.0
  • CMS version: Drupal 7.14
  • MySQL version: 5.1
  • PHP version: 5.3
Re: Error with PayPal payment
October 04, 2012, 10:09:43 am
I saw this problem after upgrading to 4.2.0.  The error message was displayed for either PayPal payment or offline payment due, and when PayPal payment was selected it did not go to the PayPal site to complete the transaction. 

(And, by the way, the problem did not appear with contribution forms, only with event registration forms.)

I applied the fix described in #8 and it worked.

Thanks.

Hounddog

  • I’m new here
  • *
  • Posts: 7
  • Karma: 0
  • CiviCRM version: 4.2.2
  • CMS version: Joomla
  • MySQL version: ?
  • PHP version: ?
Re: Error with PayPal payment
October 08, 2012, 03:07:16 pm
I can confirm Crispin's issue for 4.2.2.  The problem appears to be that this->_feeBlock is empty.

This may be a logical fallacy in the code, I don't know.  However, adding this code after line 267

if(!empty($this->_feeBlock)){

And closing the parenthesis after the new line 283, appears to fix the problem.

Should I commit this code somewhere? I'm new to civi and I'm not sure of the contribution workflow.

Deepak Srivastava

  • Ask me questions
  • ****
  • Posts: 677
  • Karma: 65
Re: Error with PayPal payment
October 09, 2012, 07:20:06 am
Hey Hounddog,

I'm unable to reproduce it. Wondering why _feeBlock is empty.

Is it possible for you to re-create error on demo ? or help me to see / investigate the problem on your system ?

What happens you create a similar new event ? do you still get that error ?

I suspect there is some weird db value or absence of 'fee' or something (may be post upgrade effect) which is causing this error.

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

Hounddog

  • I’m new here
  • *
  • Posts: 7
  • Karma: 0
  • CiviCRM version: 4.2.2
  • CMS version: Joomla
  • MySQL version: ?
  • PHP version: ?
Re: Error with PayPal payment
October 09, 2012, 06:45:00 pm
I can't seem to recreate the error on the demo server.  Possibly it is fixed in the svn version.

Deepak Srivastava

  • Ask me questions
  • ****
  • Posts: 677
  • Karma: 65
Re: Error with PayPal payment
October 10, 2012, 12:03:25 am
What happens you create a similar new event on your system ? do you still get that error for that new event ?

I guess its an upgrade / db issue, and can only be reproduced on events that have passed upgrade. Can you please verify ?
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

Hounddog

  • I’m new here
  • *
  • Posts: 7
  • Karma: 0
  • CiviCRM version: 4.2.2
  • CMS version: Joomla
  • MySQL version: ?
  • PHP version: ?
Re: Error with PayPal payment
October 14, 2012, 07:01:52 pm
I still recieve that error for a new event.

I'm having a hard time trying to use the test Joomla server, it apparently is trapped in some non-english language, and I think I don't have permissions to create events anymore.

I'm going to try and upgrade my system to the SVN version.  I will report back :D

Hounddog

  • I’m new here
  • *
  • Posts: 7
  • Karma: 0
  • CiviCRM version: 4.2.2
  • CMS version: Joomla
  • MySQL version: ?
  • PHP version: ?
Re: Error with PayPal payment
October 18, 2012, 03:50:05 pm
Double posting because reporting back.

I went to try and install the svn version, and noticed that 4.2.4 had come out.  Reasoning that it was close to the svn version (since it just came out), I gave it a shot.  The error still persists.

Given that my fix above *seems* to be a working solution, I'm going to stick with that unless people have good debugging information I can use.  I'm not really a php guru, so I'm not really sure how to check the value of variables or anything.

bradb

  • I’m new here
  • *
  • Posts: 17
  • Karma: 0
  • CiviCRM version: 4.2
  • CMS version: Joomla 2.5
  • MySQL version: 5.1.57-community
  • PHP version: 5.3
Re: Error with PayPal payment
November 01, 2012, 08:54:54 pm
an update to this, i am running civi 4.2.2 and joomla 2.5.7. experiencing this error on event registration pages, auth.net payment processor, pay later no enable. added the code that hound dog commented. error is gone. haven't tried upgrading to 4.2.4.

gsibert

  • I’m new here
  • *
  • Posts: 2
  • Karma: 0
  • CiviCRM version: 4.2.7
  • CMS version: WordPress 3.5.1
  • MySQL version: 5.5
  • PHP version: 5.4
Re: Error with PayPal payment
November 05, 2012, 09:48:40 am
I'm having same error but with Auth.net. I'm using 4.2.6 and the code suggestion in reply #19 seems to be working for me at this point.

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: Error with PayPal payment
November 05, 2012, 11:39:13 am

would be great if we can reproduce this on demo, so it can be fixed.

not sure what is different between the demo server and various folks installs

are u on php 5.3 or php 5.4?

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

leupi

  • I post frequently
  • ***
  • Posts: 192
  • Karma: 2
Re: Error with PayPal payment
November 14, 2012, 08:30:47 am
I seem to be having the same issue. I'm running Drupal 6.26 and CiviCRM 4.2.4 running on Windows Server 2008 R2 Datacenter (the powers that be forced the Windows thing on me).

When I am on the Event page > Register Now > Fill out credit card information > Continue. On the 'Confirm your registration information' page I get the following error:
Quote
warning: Invalid argument supplied for foreach() in C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Event\Form\Registration\Register.php on line 268.
I tried patching the file as per #8 but got the following:
Code: [Select]
Reversed (or previously applied) patch detected!  Assume -R? [n]This tells me that the file is already patched. Just for the hell of it I replaced my existing file with the one in #8 and tried to register again but no luck, I still get the error message. The registration seems to go through but I still need to get rid of that ugly error message.

Any thoughts?

leupi

  • I post frequently
  • ***
  • Posts: 192
  • Karma: 2
Re: Error with PayPal payment
November 14, 2012, 08:50:00 am
I made that last post without realizing that there was a second page to this thread, sorry.

I applied the fix in #19 and that worked for me.

This event was created before we upgraded to our current version of CiviCRM, if that means anything.

Pages: 1 [2] 3
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • Error with PayPal payment

This forum was archived on 2017-11-26.