PayPal payment method - strange behaviour?

  • Posts: 30
  • Thank you received: 0
12 years 5 months ago #53540

Hi Nicolas,

I have just spent all day wondering why I was not receiving IPNs from PayPal, when I realised that I had "hidden" the shop menu by making it "registered". Making it "public" re-instated the IPNs. My first question: Is it not possible to have a shop available only to "registered" users, and still maintain IPN functionality?

As I have been investigating the problem, I have noticed the following:

(a) the "Enable validation mode" No/Yes radio buttons seem to be reversed;

(b) Whether I have "Debug" selected or not, nothing is written to the payment log file (it is writable - if I enter the IPN return url in a browser, a blank entry appears in the log file).

(c) the "Refresh IPs" link does nothing except send to top-of-page anchor.

Finally, two more observations:

(a) in "Order List", the green "back" button on the first page appears to do nothing at all except send to top-of-page.

(b) If the "go to checkout" button on the "product successfully added to cart" pop-up is clicked, sometimes it will go to cart as required, sometimes it will go to an EMPTY cart.

Best regards,

John

Last edit: 12 years 5 months ago by jrm.

Please Log in or Create an account to join the conversation.

  • Posts: 82820
  • Thank you received: 13368
  • MODERATOR
12 years 5 months ago #53616

Hi,

1. You can. For example, you can set the "force a menu on the checkout" option of the Checkout tab of the configuration to a different menu which is public while your shop menu is not. That way, the notifications will also be done with the public menu.

a. No, the validation mode, if activated, disable the capture mode of PayPal and you have the validate yourself the payments on PayPal's website.

b. It's working fine on our end...

c. It refresh the list of IPs in the textarea. Since they are already up to date, it's normal that you don't see any change.

a.bis. What green black button are you talking about ?

b.bis. You might have a cache problem:
Disable the cache in Joomla configuration.
Site -> global configuration -> system -> "Cache settings".
Disable, if it's enabled, a joomla cache plugin.
Check your template' options for a potential cache option and deactivate it.

Please Log in or Create an account to join the conversation.

  • Posts: 30
  • Thank you received: 0
12 years 5 months ago #53668

Thanks for the reply, Nicolas.

1. Ah! I thought there must be a way. Thanks.

a. I understand, but my buttons seem to work in reverse - Validation "yes" - no validation required. Validation "no" - validation required. Strange.

b. Not my end!

c. There are no IPs in my text box, and refresh does not do anything.

a bis. The "back" button (see attached image) doesn't work.

b bis. I do not use a cache at all. Strange.

Best regards,

John

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82820
  • Thank you received: 13368
  • MODERATOR
12 years 5 months ago #53794

a. I yes, I think you're right. We'll look at that for next release.

c. You don't need to have IPs there. We found the problem and we'll fix that for the next release.

a.bis
As you can see on our demo website, that works fine for us:
www.demo.hikashop.com/index.php?option=c...er&Itemid=96&lang=en
Do you have a javascript error on your page ? Could you give a link/test account maybe ?

Please Log in or Create an account to join the conversation.

  • Posts: 19
  • Thank you received: 0
12 years 4 months ago #55448

nicolas wrote: 1. You can. For example, you can set the "force a menu on the checkout" option of the Checkout tab of the configuration to a different menu which is public while your shop menu is not. That way, the notifications will also be done with the public menu.


Can you please provide a more step-by-step guide to show how to configure it?

My shop is for registered users, and the checkout menu is for registered.
When paypal returns it doesn't change the status of the order to confirmed, but if I set checkout menu to public it works.

I don't want to change the registered menu and the flow on pages for the user: he should come back to the checkout as now with in the same active menu and modules.

What kind of public menu should I use in "force a menu on the checkout"? Another public checkout? Another random public menu? What is the behaviour?
Is it alternatively possible to solve the situation using 'Return url' in the paypal plugin?

Thanks!

Please Log in or Create an account to join the conversation.

  • Posts: 82820
  • Thank you received: 13368
  • MODERATOR
12 years 4 months ago #55530

You can use any public menu in that option.
There is not much to explain. Click on the dropdown of that option, select a public menu and save the configuration.

The return URL of the plugin is for you to say where the user should go once he comes back from PayPal. That's not related to the payment notification URL.

Please Log in or Create an account to join the conversation.

  • Posts: 19
  • Thank you received: 0
12 years 4 months ago #55624

Ok, I started to understand now how it's working and I found a problem.

If I pay starting from the checkout, it's working correctly as you said (it uses the provided itemid) because the notification URL uses this Itemid.
But if I pay starting from Orders "pay now", it still uses its private itemid and this makes the notification not working.

A possible solution would be to force the selected itemid in the 10 seconds redirect page, so that no matter where you come from it always uses the selected itemid for the notification (if defined, otherwise use the one you're coming from).

Please Log in or Create an account to join the conversation.

  • Posts: 82820
  • Thank you received: 13368
  • MODERATOR
12 years 4 months ago #55734

That's a valid point. Didn't think about the "pay now" button.
Then try to add the code:

				$itemid_for_checkout = $config->get('checkout_itemid','0');
				if($itemid_for_checkout){
					global $Itemid;
					$Itemid = $itemid_for_checkout;
				}
before the line:
if(method_exists($data,'onAfterOrderConfirm')) $data->onAfterOrderConfirm($order,$paymentData,$order->order_payment_id);
in the file components/com_hikashop/controllers/order.php
That should allow for the Itemid to be changed to the one of the "force menu on checkout" option when being redirected.

Last edit: 12 years 4 months ago by nicolas.

Please Log in or Create an account to join the conversation.

  • Posts: 19
  • Thank you received: 0
12 years 4 months ago #55811

nicolas wrote: That should for the Itemid to be changed to the one of the "force menu on checkout" option when being redirected.

It works, thanks!

Please Log in or Create an account to join the conversation.

Time to create page: 0.078 seconds
Powered by Kunena Forum