WEB.CONFIG FILE
<add key="MerchantId" value=" MYSITE "/>
<add key="CurrencyType" value="INR"/>
<add key="TypeField1" value="R"/>
<add key="SecurityId" value="mysite"/>
<add key="TypeField2" value="F"/>
<add key="AdditionlaInfo1" value="NA"/>
<add key="AdditionlaInfo2" value="NA"/>
<add key="ReturnUrl" value="http://www.mysite.com/ReturnFromBillDesk.aspx"/>
<add key="BillDeskUrl" value="https://www.billdesk.com/pgidsk/PaymentEntry.jsp"/>
<add key="CheckSumKey" value="9FGcERMK1GfF"/>
----------------------------
<form name=’abc’ method='POST'
action='https://www.billdesk.com/pgidsk/pgijsp/MerchantPaymentoption.jsp'>
<input type='hidden' name='txtCustomerID' value='1073234'>
<input type='hidden' name='txtTxnAmount' value='2400.30'>
<input type='hidden' name=' txtAdditionalInfo1' value='
Identity of Merchant website with Billdesk '>
<input type='hidden' name=' txtAdditionalInfo2'
value='USD'>
<input type='hidden' name=' txtAdditionalInfo3'
value='Kerala Backwaters'>
<input type='hidden' name=' txtAdditionalInfo4' value='25-
Sep-08'>
<input type='hidden' name=' txtAdditionalInfo5' value='28-
Sep-08'>
<input type='hidden' name=' txtAdditionalInfo6' value='2'>
<input type='hidden' name=' txtAdditionalInfo7' value='1'>
<input type='hidden' name='RU'
value='https://payment.merchant.com'>
-----------------------
<html>
<head id="Head1" runat="server">
<title>Paymenttitle>
<script type="text/javascript">
function myfunc ()
{
var frm = document.all("form2");
frm.submit();
}
window.onload = myfunc;
script>
head>
<body>
<form id="form2" method="post" action="https://www.billdesk.com/ Paymentoption.jsp" name="form2">
<input type="hidden" name="txtCustomerID"
value="<%=Request("txtCustomerID")%>" />
<input type="hidden" name="txtTxnAmount"
value="<%=Request("txtTxnAmount")%>" />
<input type="hidden" name="txtAdditionalInfo1"
value="<%=Request("txtAdditionalInfo1")%>" />
<input type="hidden" name="txtAdditionalInfo2"
value="<%=Request("txtAdditionalInfo2")%>" />
<input type="hidden" name="txtAdditionalInfo3"
value="<%=Request("txtAdditionalInfo3")%>" />
<input type="hidden" name="txtAdditionalInfo4"
value="<%=Request("txtAdditionalInfo4")%>" />
<input type="hidden" name="txtAdditionalInfo5"
value="<%=Request("txtAdditionalInfo5")%>" />
<input type="hidden" name="txtAdditionalInfo6"
value="<%=Request("txtAdditionalInfo6")%>" />
<input type="hidden" name="txtAdditionalInfo7"
value="<%=Request("txtAdditionalInfo7")%>" />
<input type="hidden" name="RU" value="http://www.mahindrahomestays.com/Pages/confirmation.aspx" />
form>
body>
html>
----------------------------------
string _paymentResp = Request.Form["msg"];
string[] arrResponse = _paymentResp.Split('|'); //PG
string merchantId = arrResponse[0];
string _customerId = arrResponse[1];
string txnReferenceNo = arrResponse[2];
string bankReferenceNo = arrResponse[3];
string txnAmount = Convert.ToDecimal(arrResponse[4]);
string bankId = arrResponse[5];
string bankMerchantId = arrResponse[6];
string txnType = arrResponse[7];
string currency = arrResponse[8];
string itemCode = arrResponse[9];
string securityType = arrResponse[10];
string securityId = arrResponse[11];
string securityPassword = arrResponse[12];
string txnDate = arrResponse[13]; //dd-mm-yyyy
string authStatus = arrResponse[14];
string settlementType = arrResponse[15];
string additionalInfo1 = arrResponse[16];
string additionalInfo2 = arrResponse[17];
string additionalInfo3 = arrResponse[18];
string additionalInfo4 = arrResponse[19];
string additionalInfo5 = arrResponse[20];
string additionalInfo6 = arrResponse[21];
string additionalInfo7 = arrResponse[22];
string errorStatus = arrResponse[23];
string _errorDescription = arrResponse[24]
references:- http://techgeek14.blogspot.com/2012/03/billdesk-payment-gateway-integration.html
https://www.dotnetfunda.com/articles/show/1341/bill-desk-payment
No comments:
Post a Comment