LemonStand Forum: Payment module redirection - LemonStand Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Payment module redirection

#1 User is offline   caddoo 

  • Member
  • Group: Members
  • Posts: 10
  • Joined: 01-September 11

Posted 16 January 2012 - 03:09 AM

I'm currently working on a payment module for LS and the final piece that needs doing is redirecting the user on a successful payment to the defined redirect page.

My current code is:

<?php
...
                            if (!isset($backend))
                            {     
                                $return_page = $order->payment_method->receipt_page;
                                if ($return_page)
                                    Phpr::$response->redirect(root_url($return_page->url.'/'.$order->order_hash).'?utm_nooverride=1');
                                else
                                    throw new Phpr_SystemException('Redirection receipt page is not found.');
                            } else
                                Phpr::$response->redirect(root_url('/shop/orders/payment_accepted/'.$order->id.'?utm_nooverride=1&nocache'.uniqid()));
...
?>

But looking in the docs i see no reference to the receipt_page property.

This currently redirects to this: http://{Order Hash}?utm_nooverride=1

Any ideas?
0

#2 User is offline   Eric 

  • Developer
  • PipPipPip
  • Group: Members
  • Posts: 1,290
  • Joined: 04-August 10
  • LocationVancouver, Canada

Posted 16 January 2012 - 10:52 AM

Hi,

$receipt_page is documented here: http://lemonstandapp...gration_method/

It's included for most payment methods on the first tab, for example Auth.net DPM.
0

Share this topic:


Page 1 of 1

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users