简体   繁体   中英

paypal after successful payment, how to redirect user to new page

Hi i'm implementing paypal with codeigniter. i'm using paypal integration wizard to generate the code: https://www.paypal-labs.com/integrationwizard/ .

in the return url, i call a function named confirmorder() to handle successful payment. By paypal default, the payment will be handled in a lightbox/a new page. I want that after user make payment successfully, and lightbox closes, the partent page (the one under lightbox, also where user press 'pay by paypal') will direct to home page. but no matter how i change the code, the redirection always happen in the payment handle page, not the parent page.

anyone got some idea on this?

Thanks

What I understand is that you are let user to make payment through a dialog box right? In this condition you should redirect the page using javascript by redirecting parent window using opener.location.href = '/redirecturl'; and after redirecting you should also close the dialog box using close(); method of javascript

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM