also; I create a form in PostProcessPayment and post it(POST method necessary). Page goes to the Bank Payment Page and return result.
public void PostProcessPayment(PostProcessPaymentRequest postProcessPaymentRequest)
{//3.90
var myForm = "<form action=\"{0}\" method=\"POST\" />" +
"<input type=\"hidden\" name=\"secure3dsecuritylevel\" value=\"CUSTOM_PAY\" />" +
"<input type=\"hidden\" name=\"successurl\" value=\"{1}\" />" +
"<input type=\"hidden\" name=\"errorurl\" value=\"{2}\" />" +
"<input type=\"hidden\" name=\"secure3dhash\" value=\"{3}\" />" +
"</form>"+
"<script> document.forms[0].submit();</script>";
_httpContext.Response.Clear();
_httpContext.Response.Write(myForm);
_httpContext.Response.End();
}
but at 4.00 not worked.
void IPaymentMethod.PostProcessPayment(PostProcessPaymentRequest postProcessPaymentRequest)
{//4.00
byte[] data = System.Text.Encoding.UTF8.GetBytes(myForm);
_httpContextAccessor.HttpContext.Response.Clear();
_httpContextAccessor.HttpContext.Response.Body.Write(data, 0, data.Length);
_httpContextAccessor.HttpContext.Response.Body.Close();
}
As a result, it writes myForm to the page as text.
PaypalStandart is not a good example for me. I need to send form with POST.
Is there any solution suggestion?