I've been trying to pass the address information over to PayPal sandbox (and a live account) by Form Tools API but only the first name, last name, email address and amount are passed... I read the FormTools docs and PayPal docs and tried what paypal said about changing:
<input type="hidden" name="cmd" value="_xclick">
to:
<input type="hidden" name="cmd" value="_ext-enter">
<input type="hidden" name="redirect_cmd" value="_xclick">
I tried putting that directly in the form and tried playing around with config.inc.php like this:
from:
$paypal["cmd"] = "_xclick";
to:
$paypal["cmd"] = "_ext-enter";
$paypal["redirect_cmd"] = "_xclick";
This is the form I'm sending:
<form action="<?php echo $_SERVER["PHP_SELF"]?>" method="post">
<INPUT TYPE="hidden" NAME="item_name" VALUE="Player Registration">
<INPUT TYPE="hidden" NAME="firstname" VALUE="<?=@$fields['First_Name']?>">
<INPUT TYPE="hidden" NAME="lastname" VALUE="<?=@$fields['Last_Name']?>">
<INPUT TYPE="hidden" NAME="email" VALUE="<?=@$fields['Email_Address']?>">
<INPUT TYPE="hidden" NAME="address1" VALUE="<?=@$fields['Address1']?>">
<INPUT TYPE="hidden" NAME="address2" VALUE="<?=@$fields['Address2']?>">
<INPUT TYPE="hidden" NAME="city" VALUE="<?=@$fields['City']?>">
<INPUT TYPE="hidden" NAME="state" VALUE="<?=@$fields['State']?>">
<INPUT TYPE="hidden" NAME="zip" VALUE="<?=@$fields['ZipCode']?>">
<INPUT TYPE="hidden" NAME="country" VALUE="US">
<INPUT TYPE="hidden" NAME="currency_code" VALUE="USD">
<INPUT TYPE="hidden" NAME="amount" VALUE="<?php
if (@$fields["Registered_Players"]==1) echo "25.00";
if (@$fields["Registered_Players"]==2) echo "50.00";
if (@$fields["Registered_Players"]==3) echo "75.00";
?>">
<BR>
<label>
<input type="submit" name="Registration2" id="Registration2" value=" Proceed to Payment " style="font-weight: bold;">
</label><BR><BR></form>
When I look at the source, all the values are there and the form completes successfully. Can anyone shed some light please?
<input type="hidden" name="cmd" value="_xclick">
to:
<input type="hidden" name="cmd" value="_ext-enter">
<input type="hidden" name="redirect_cmd" value="_xclick">
I tried putting that directly in the form and tried playing around with config.inc.php like this:
from:
$paypal["cmd"] = "_xclick";
to:
$paypal["cmd"] = "_ext-enter";
$paypal["redirect_cmd"] = "_xclick";
This is the form I'm sending:
<form action="<?php echo $_SERVER["PHP_SELF"]?>" method="post">
<INPUT TYPE="hidden" NAME="item_name" VALUE="Player Registration">
<INPUT TYPE="hidden" NAME="firstname" VALUE="<?=@$fields['First_Name']?>">
<INPUT TYPE="hidden" NAME="lastname" VALUE="<?=@$fields['Last_Name']?>">
<INPUT TYPE="hidden" NAME="email" VALUE="<?=@$fields['Email_Address']?>">
<INPUT TYPE="hidden" NAME="address1" VALUE="<?=@$fields['Address1']?>">
<INPUT TYPE="hidden" NAME="address2" VALUE="<?=@$fields['Address2']?>">
<INPUT TYPE="hidden" NAME="city" VALUE="<?=@$fields['City']?>">
<INPUT TYPE="hidden" NAME="state" VALUE="<?=@$fields['State']?>">
<INPUT TYPE="hidden" NAME="zip" VALUE="<?=@$fields['ZipCode']?>">
<INPUT TYPE="hidden" NAME="country" VALUE="US">
<INPUT TYPE="hidden" NAME="currency_code" VALUE="USD">
<INPUT TYPE="hidden" NAME="amount" VALUE="<?php
if (@$fields["Registered_Players"]==1) echo "25.00";
if (@$fields["Registered_Players"]==2) echo "50.00";
if (@$fields["Registered_Players"]==3) echo "75.00";
?>">
<BR>
<label>
<input type="submit" name="Registration2" id="Registration2" value=" Proceed to Payment " style="font-weight: bold;">
</label><BR><BR></form>
When I look at the source, all the values are there and the form completes successfully. Can anyone shed some light please?