Click to See Complete Forum and Search --> : First simple pay pal


oo7ml
01-27-2009, 05:15 PM
Hi, i have just created a site for a client. I have a form where the user enters in their details. Once the form is submitted, it sends the details to my client's email address. I now also need the user to be re-directed to Pay Pal where they will be charged their $100 deposit for the service.

Can someone help me with this. I do not need any pay pal buy buttons as it is a flat charge of $100. Thanks in advance

Chazzl
01-27-2009, 06:23 PM
What server-side language do you have available?

You might be able to setup an http forward to Paypal.

— Chazz L

oo7ml
01-28-2009, 03:37 AM
Hi, thanks for the reply, i am using PHP

Chazzl
01-28-2009, 10:03 AM
Depending on what your script does after it processes the form submission, you can simply forward the user to a Paypal screen using the header() function. — http://us3.php.net/header

First, you'll need to create a button through the merchant tab in Paypal... but you won't actually be using the html code it generates; just the URL.

When you get through the setup process and the html code is shown to you, find the Email tab and copy that URL for your PHP header() function.


<?php
// Process email response...

// Forward to Paypal
header("Location: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=2826911");
exit();
?>


That should do it for something basic. Let me know if this doesn't work with your script or if you need to track transaction ID's.


— Chazz L