POST params not sent when redirected

AntoineVerger
Contributor
Contributor

Hi all,

 

I´m running into an issue that I detected today. I have the following paypal button config :

 

 

<form action="https://www.paypal.com/cgi-bin/webscr" method="post" id="paypalFormId">
         <input type="hidden" name="cmd" value="_xclick">
<input type="hidden" name="business" value="mybusinessID">
<input type="hidden" name="lc" value="DE">
<input type="hidden" name="button_subtype" value="services">
<input type="hidden" name="no_note" value="1">
<input type="hidden" name="no_shipping" value="2">
<input type="hidden" name="item_name" value="Studiotest Tageskarte">
<input type="hidden" name="amount" value="1.00">
<input type="hidden" name="custom" value="somecustom infos needed in the redirection">
<input type="hidden" name="rm" value="2">
<input type="hidden" name="return" value="myreturnUrl">
<input type="hidden" name="cancel_return" value="myCancelUrl">
<input type="hidden" name="currency_code" value="EUR">
<input type="hidden" name="notify_url" value="myIPNUrl">
<input type="hidden" name="bn" value="PP-BuyNowBF:btn_buynowCC_LG.gif:NonHosted"> <div class="row"> <button type="submit" class="btn btn-submit-next pull-right">Bestellung abschließen</button> </div> </form>

I didn´t change anything that could impact this code in the last days, nevertheless, redirection POST parameters are missing and redirection is a GET now and not a POST method anymore, even with the rm=2 !

 

Any idea, what´s going on ?

 

Best regards,

 

Antoine 

 

Login to Me Too
6 REPLIES 6

MTS_Andre
Moderator
Moderator

Hey Antoine, to get the parameters in the redirection URL make sure that a valid returnURL is passed, like in your example, and that the business email variable is an account that has PDT enabled. You can check here about PDT: https://developer.paypal.com/docs/classic/products/payment-data-transfer/

Login to Me Too

AntoineVerger
Contributor
Contributor
Hi Andre,

thanks a lot for your feedback !
PDT was never enabled but IPN was so far and the problem just appeared last week without any change in our checkout implementation. Any change on Paypal side ? I understand that PDT is the way to go in our case but it represents some efforts on our side to do the switch.
Regards,

Antoine
Login to Me Too

ThisIsMe2000
Contributor
Contributor

I also have this issue - I don't use PDT - I use IPN.  My html form worked great until recently.  So what has changed?

 

Issue description

Using IPN to validate and in my form I have:

<input type="hidden" name="cmd"  value="_xclick"/>	
<input type="hidden" name="business" value="<?php echo $paypalbizemailaddress;?>"> 
<input type="hidden" name="item_name" value="<?php echo $product ?>">
<input type="hidden" name="currency_code" value="USD"> 
<input type="hidden" name="amount" value="<?php echo $price;?>"> 
<input type="hidden" name="custom" value="<?php echo $custom_data ;?>"> 
<input type="hidden" name="item_number" value="<?php echo $itemId;?>">
<input type="hidden" name="first_name" value="<?php echo $fname;?>">
<input type="hidden" name="last_name" value="<?php echo $lname;?>">
<input type="hidden" name="city" value="<?php echo $city;?>">
<input type="hidden" name="country" value="US"> 
<input type="hidden" name="night_phone_a" value="<?php echo $ctycode;?>"> 
<input type="hidden" name="night_phone_b" value="<?php echo $phone;?>">
<input type="hidden" name="email" value="<?php echo $email;?>">
<input type="hidden" name="no_shipping" value="1"> 
<input type="hidden" name="return"  value="success.php" />
<input  type="hidden" name="notify_url" value="ipn.php" />
<input  type="hidden"  name="cancel_return"  value="cancel.php" />
 <input type="hidden" name="rm" value="2">

I have IPN turned on in sandbox profile and pointing to my notify_url (ipn.php).
I have Auto Return turned On and pointing to my return url (success.php).
All my URLs are HTTPS

 

This works fine (both in sandbox and live) and I receive the IPN data back to my ipn.php as POST variables and I can do required DB processing with it. However, recently the POST variables have stopped coming through to my return (success.php) URL. When I can't get the POST variables at my return URL (success.php), it's harder to present a "Thank you for the order - your order is complete" message.

 

So, I have tried with PDT and it now correctly returns the GET vars to success.php without issue, however I prefer to work with POST and I don't like the ugly GET querystring in the URL which can also be manipulated by user.  It looks like this:
success.php?amt=300.00&cc=USD&cm=2-%7C-4&item_name=productabc&item_number=102323732&st=Completed&tx=3PW6232xxxxxxx118529437

 

Why have POST vars stopped coming to my return URL? This form has been working without issue for 12 months, now it stops recently.

I thought that was the purpose of the rm value "2" is to receive POST vars back to return URL (as described here: in method three https://www.paypal-knowledge.com/infocenter/index?page=content&id=FAQ1188

 

Is there an issue with PayPal or is this a result of some change I am not aware of?
Thanks

 

Login to Me Too

sonjarusso
New Community Member

I'm experiencing the same issue starting on 2017/09/11 No code changes, no advise and no more POSTed back variables after a PayPal transaction! Very disappointing... someone can shed a light on this issue???

The 'rm' variable now become useless! And i don't want to use PDT, i just want to get POST variables after a payment, it worked in this way since years

Login to Me Too

ZoneF
Member
Member

Any developments? I am going crazy with this. Was working for years and no documentation nothing about any changes.

Login to Me Too

solace2000
Contributor
Contributor

It would appear that PayPal using PDT does not send any POSTED variables and instead you must use GET to query the transaction parameters.

 

https://github.com/paypal/pdt-code-samples/blob/master/paypal_pdt.php

 

It would be nice if there was some official clarification around whether using "rm" = "2" is now useless or not.

In other words, send all variables by POST seems pointless if using PDT

 

 

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.