On the page there is a form with the data:

<form name="SendOrder" method="post" action="https://testpay.kkb.kz/jsp/process/logon.jsp"> <input type="hidden" name="Signed_Order_B64" size="100" value="{$bookingpay}"> <input type="hidden" name="email" value="{$val.email}"> <input type="hidden" name="Language" value="rus"> <input type="hidden" name="BackLink" value="http://suite/?page=payed"> <input type="hidden" name="PostLink" value="http://suite/?page=success"> 

After clicking, the form is sent to the payment https://testpay.kkb.kz/jsp/process/logon.jsp in the form is transferred to xml on my part. After passing the check and payment, the bank sends the xml "response" to the url. And the user returns to the site via BackLink. The routing page is described as follows:

 case 'success': $response = successpay($_POST["response"]); $smarty->display('booking.tpl'); break; case 'payed': $smarty->display('successpay.tpl'); break; case 'failpay': $smarty->display('failure.tpl'); break; 

successpay is in the functions file common.php Questions: 1. Will the $ _POST ["response"] process occur? Because user does not access page = success page, but page = payed

  • Try to state your question more clearly. the pages themselves go nowhere, and for some actions, some queries are executed. - teran

2 answers 2

Of course, "see a parallel POST request" is impossible. look in this case can and should be in the database.

The script that processes the POST request from the bank should not output anything to anyone, and assigning variables to the Smart in it is meaningless. All he has to do is to write to the database information received from the bank about the success or failure of the payment.

And the backlink script should already look in the database and look for this information there.

  • The smart part is needed in order not to go straight to common.php, unless this implementation is case 'success': $ response = successpay ($ _ POST ["response"]); no sense? - Den
  • Have you read the entire answer or just a line about smarti? WHAT are you going to show the bank robot that accesses your site? He will not appreciate what a beautiful logo you have - Ipatiev
  • Thanks for the logo, which was not seen) Essentially: $ smarty-> assign (successpay ($ _ POST ["response"])); after it enters the function function successpay ($ response) - Den
  • Well, just write successpay ($ response) without smarti. in any case, this is not the main thing - Ipatiev

Developer tools open. There is a special tab. For chrome -

here

Displays which pages were requests, how much time they took and much more.

  • This form is posted to the bank’s server, after payment they are sent via the Postlink xml url, and returned to the site via the BackLink user. - Den
  • @Den I still do not understand what you want from us. I think the others do not understand either. Can you get together and fully, comprehensively, clearly, competently, consistently and logically, everything is stated from beginning to end, by editing your question? - n.osennij
  • Fixed. Ipatiev understood what I meant. - Den