vozzek Posted January 19, 2015 Share Posted January 19, 2015 Hi everyone, I've been running a self-written php shopping cart for the last 8 years, with lots of success. Recently however, the credit card processor (Linkpoint) I use upgraded their gateway, and now I have a problem. Basically, the last page of my checkout does a _POST to a specific url for their gateway. I send through a bunch of <input> variables, some of them hidden, but all of them check out okay. I have combed over their specs, made sure I'm not sending any bad characters, made sure I've got the right format for the fields they want, etc... Right now the transaction is successful, the customer's card is charged, but Linkpoint's system is returning an error message: We are unable to process your request due to invalid data. Long story short, their support staff has asked me to "send them the xml string" via email. I have no idea how to do this (even after spending a few hours online trying to figure it out). Is there a simple way to generate the xml string that's being passed during the _POST? Some kind of php code I can incorporate into my final checkout page, run a test transaction, and maybe write the string out somewhere so I can get it to them? Any help you guys could give me would be greatly appreciated. Thanks in advance!Danny Quote Link to comment Share on other sites More sharing options...
Solution Barand Posted January 19, 2015 Solution Share Posted January 19, 2015 Either Echo to the page and view the source Echo it to the page using htmlentities() echo htmlentities($xml_string); then you can copy/paste it. Quote Link to comment Share on other sites More sharing options...
vozzek Posted January 19, 2015 Author Share Posted January 19, 2015 Sorry, I'm not sure I understand. How do I build $xml_string? I've never done that. It's null right now, unless I set it? Quote Link to comment Share on other sites More sharing options...
Barand Posted January 19, 2015 Share Posted January 19, 2015 How do I build $xml_string? I've never done that. Then what are you sending to Linkpoint, if it requires an xml string? Quote Link to comment Share on other sites More sharing options...
vozzek Posted January 19, 2015 Author Share Posted January 19, 2015 Okay, here's the gateway url: <FORM action="https://connect.firstdataglobalgateway.com/IPGConnect/gateway/processing" method="post" name="ccform" id="ccform" onSubmit="return validateCC();" style="margin:0;"> Within the form are a bunch of inputs. Some examples: <select name="paymentMethod" id="paymentMethod"> <option value="" selected>Please Select</option> <option value="A">American Express</option> <option value="V">Visa</option> <option value="M">Master Card</option> <option value="D">Discover</option> </select> <select name="expmonth" id="expmonth"> <option value="" selected>--Month--</option> <option value="1">January</option> <option value="2">February</option> <option value="3">March</option> <option value="4">April</option> <option value="5">May</option> <option value="6">June</option> <option value="7">July</option> <option value="8">August</option> <option value="9">September</option> <option value="10">October</option> <option value="11">November</option> <option value="12">December</option> </select> So on and so forth. There are also a few hidden inputs for customer information, billing info, order comments, etc... Then the form ends with </form> As far as I've always known, I'm simply posting a bunch of data to the gateway url. Which is why I was confused when the guy said: "I need to see the xml request (envelope) being sent to us" "What?" I asked him. "Everything you send is wrapped in an xml envelope. You have to print it (get the server to print it?) and email it to us, so we can troubleshoot whether it's sending anything bad." Quote Link to comment Share on other sites More sharing options...
Barand Posted January 19, 2015 Share Posted January 19, 2015 does this help? http://www.firstdata.com/downloads/marketing-merchant/fdgg-web-service-api-v3.pdf Quote Link to comment Share on other sites More sharing options...
vozzek Posted January 19, 2015 Author Share Posted January 19, 2015 Hmmm... interesting. They have a few gateways, and the one you linked is for the API. I am using their "connect 2.0" gateway. The integration guide for that one is here: http://www.firstdata.com/downloads/marketing-merchant/fdgg-connect-2.0-integration-guide.pdf No mention of xml there really. If the two different support reps I spoke to today both assumed I was using the API - when I specifically mentioned connect 2.0 - I'm gonna kick someone's ass... Quote Link to comment Share on other sites More sharing options...
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.