I am trying to connect an e-commerce system to a payment gateway (located in
Hong Kong). The gateway takes values in the form of a simple form submit -
however, the results (i.e. authorisation code, status, etc...) are not
returned to a separate HTML page (I am not given the option of defining a
resulting HTML page to which the results are sent) - but rather I must
receive them within the same page through a data stream somehow.
Does anyone have an idea how this is done? The example code given by the
clearing house is in JSP - so not much use to me. Actually that recommends I
send the data through a stream too - but that seems more complicated than is
necessary surely?
So far, i've done :
print "<form name=\"paydolla r\" method=\"POST\"
action=\"https://www.paydollar.c om/b2c2/eng/payment/payForm.jsp\">" ;
print "<input type=\"hidden\" name=\"orderRef \" value=\"$cus_no \">";
print "<input type=\"hidden\" name=\"amount\" value=\"$finalp \">";
print "<input type=\"hidden\" name=\"currCode \" value=\"344\">" ;
print "<input type=\"hidden\" name=\"lang\" value=\"E\">";
print "<input type=\"hidden\" name=\"merchant Id\" value=\"xxxx\"> ";
print "<input type=\"hidden\" name=\"pMethod\ " value=\"$credit _type\">";
print "<input type=\"hidden\" name=\"epMonth\ " value=\"$credit _expmo\">";
print "<input type=\"hidden\" name=\"epYear\" value=\"$credit _expyr\">";
print "<input type=\"hidden\" name=\"cardNo\" value=\"$credit _no\">";
print "<input type=\"hidden\" name=\"cardHold er\" value=\"$cc_hol der\">";
print "<input type=\"hidden\" name=\"remark\" value=\"\">";
print "<input type=\"hidden\" name=\"payType\ " value=\"H\">";
print "</form>";
.... and within the <body> tag I have onLoad="paydoll ar.submit();" - so my
form is successfull submitting automatically after the PHP script carries
out a few other functions locally (i.e. store orders to the database).
What stumps me is how to receive the resulting data from within the same
page.
Any help would be appreciated. Thanks!
Terence Parker
Hong Kong). The gateway takes values in the form of a simple form submit -
however, the results (i.e. authorisation code, status, etc...) are not
returned to a separate HTML page (I am not given the option of defining a
resulting HTML page to which the results are sent) - but rather I must
receive them within the same page through a data stream somehow.
Does anyone have an idea how this is done? The example code given by the
clearing house is in JSP - so not much use to me. Actually that recommends I
send the data through a stream too - but that seems more complicated than is
necessary surely?
So far, i've done :
print "<form name=\"paydolla r\" method=\"POST\"
action=\"https://www.paydollar.c om/b2c2/eng/payment/payForm.jsp\">" ;
print "<input type=\"hidden\" name=\"orderRef \" value=\"$cus_no \">";
print "<input type=\"hidden\" name=\"amount\" value=\"$finalp \">";
print "<input type=\"hidden\" name=\"currCode \" value=\"344\">" ;
print "<input type=\"hidden\" name=\"lang\" value=\"E\">";
print "<input type=\"hidden\" name=\"merchant Id\" value=\"xxxx\"> ";
print "<input type=\"hidden\" name=\"pMethod\ " value=\"$credit _type\">";
print "<input type=\"hidden\" name=\"epMonth\ " value=\"$credit _expmo\">";
print "<input type=\"hidden\" name=\"epYear\" value=\"$credit _expyr\">";
print "<input type=\"hidden\" name=\"cardNo\" value=\"$credit _no\">";
print "<input type=\"hidden\" name=\"cardHold er\" value=\"$cc_hol der\">";
print "<input type=\"hidden\" name=\"remark\" value=\"\">";
print "<input type=\"hidden\" name=\"payType\ " value=\"H\">";
print "</form>";
.... and within the <body> tag I have onLoad="paydoll ar.submit();" - so my
form is successfull submitting automatically after the PHP script carries
out a few other functions locally (i.e. store orders to the database).
What stumps me is how to receive the resulting data from within the same
page.
Any help would be appreciated. Thanks!
Terence Parker