Peteman Posted April 10, 2004 Posted April 10, 2004 My payment gateway doesn't want me sending credit card information directly to them, they want to have it processed on their page, using the following code. <form method = "post" action = "https://merchants.firstatlanticcommerce.com/order.cfm"> <input type = "hidden" name = "id" value = merchant ID"> <input type = "hidden" name = "amount" value = "total amount of sale"> <input type = "hidden" name = "item1" value = "name of first item"> <input type = "hidden" name = "qty1" value = "quantity of first item"> <input type = "hidden" name = "item2" value = "name of second item"> <input type = "hidden" name = "qty2" value = "quantity of second item"> <input type = "hidden" name = "item3" value = "name of third item"> <input type = "hidden" name = "qty3" value = "quantity of third item"> <input type = "submit" value = "submit order"> <?form> This is a fairly straightforward piece of HTML but unfortunately I am not so up on the php - I need to assign my vairables to make this work and idealy would like to make it into a full working module. NOW... I don't want to have to get the php manual out and code it all from the start - anyone know what is the closest module that I can interfere with or change to get mine to work? peteman Quote
Guest Posted April 10, 2004 Posted April 10, 2004 dont know if i would trust a processing company in bermuda Quote
Peteman Posted April 10, 2004 Author Posted April 10, 2004 To be honest I don't have a lot of choice. I live in Bermuda. I have almost got it sorted though. I am just trying to work out how to process the returned variables. I am using the SECpay module as a template. Taking a lot of stuff out - adding a few bits in. Any input will still be appreciated though. (apart from the slagging off of Bermuda - not very constructive!) :angry: Cheers peteman Quote
♥ecartz Posted April 11, 2004 Posted April 11, 2004 I would start with something like the PayPal module and modify the process_button function to include the hidden variables you need. Then you need to modify the before_process function to catch the gateway's response. Hth, Matt Quote Always back up before making changes.
Guest Posted October 15, 2004 Posted October 15, 2004 Hi this is my first post. I am trying to do something similar but after payment confirmation, customer goes back to the log in page. Then you need to modify the before_process function to catch the gateway's response. Hth, Matt <{POST_SNAPBACK}> Matt, can you be more specific? This is the responce code from my bank (WinBank): in case of success: <% ? Get output parameters Dim transactionid transactionid= Request.Form("transactionid") Dim merchantreference merchantreference = Request.Form("merchantreference") Dim responsecode Responsecode = Request.Form("responsecode") Dim responsedescription responsedescription = Request.Form("responsedescription") Dim retrievalref retrievalref = Request.Form("retrievalref") Dim approvalcode approvalcode = Request.Form("approvalcode") Dim errorcode errorcode = Request.Form("errorcode ") Dim errordescription errordescription = Request.Form("errordescription") Dim amount Amount = Request.Form("amount") Dim installments Installments = Request.Form("installments") Dim cardtype cardtype = Request.Form("cardtype") Dim langid Langid = Request.Form("langid") Dim parameters Parameters = Request.Form("parameters") ?Respond to user Response.write ?Η πληρωμή ολοκληρώθηκε επιτυχώς. Αριθμός πληρωμής: ? & transactionid ? Log in local database all output parameters %> in case of failure: <% ? Get output parameters Dim transactionid, transactionid= Request.Form("transactionid") Dim merchantreference merchantreference = Request.Form("merchantreference") Dim responsecode Responsecode = Request.Form("responsecode") Dim responsedescription responsedescription = Request.Form("responsedescription") Dim retrievalref retrievalref = Request.Form("retrievalref") Dim approvalcode approvalcode = Request.Form("approvalcode") Dim errorcode errorcode = Request.Form("errorcode ") Dim errordescription errordescription = Request.Form("errordescription") Dim amount Amount = Request.Form("amount") Dim installments Installments = Request.Form("installments") Dim cardtype cardtype = Request.Form("cardtype") Dim langid Langid = Request.Form("langid") Dim parameters Parameters = Request.Form("parameters") ? Check output parameters ? Respond to user If errorcode <> 0 then Response.write ?Λάθος κατά την εκτέλεση της πληρωμής: ? & errordescription Else Response.write ?Η πληρωμή απέτυχε: ? & responsedescription End If ? Log in local database all output parameters %> Any ideas would be more than apreciated Thanks in advance Quote
Guest Posted October 19, 2004 Posted October 19, 2004 Help anyone? All i need is some directions on how to put the above variables in function before_process. thanks again Patmanx Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.