Displaying returned XML in another PHP page
Posted on
16th Feb 2014 07:03 pm by
admin
I have an online payment form that will return XML given if a payment is successful or declines. I am using PHP cURL to do this, and it all works from the standpoint of approving or denying transactions. However, what I want to do is have it redirect to a new page and display the output in a regular format (minus the XML brackets and such), but cannot get it to carry the data over from the processing page to the results page.
This is the tag I'm using in the processing page to direct when a payment is successful:
Header("Location: /Approved.php?approvalcode=" . $xdoc2->approvalcode . "");
Currently it is passing just the approval code in the URL, but I am going to expand on this after I get the page working properly. Let's say this is part of my XML response I get back when I hit the server and post all the values it is looking for:
[errorcode] => 0 [errordesc] => Successful. [responsecode] => 1 [response] => 1 - APPROVED [approvalcode] => 766251
What needs to be coded in the Approved.php page to ensure these values are captured and displayed? This is an HTTPS setup, and from what I've read $_SESSION probably isn't the way to go (unless I'm told otherwise here), and I do not at all want to use cookies unless I have no choice. I've tried echo statements and $_GET statements but nothing is working, and I know it's because I'm missing something but cannot figure out what.
No comments posted yet
Your Answer:
Login to answer
181
14
Other forums
Changing files over
Just thought I'd start with the new forums looking really nice .
Ok basically I've made this
SAP Management Console is blank
Dear All ,
I am facing problem in my des sever suddely in SAP Management Console is blank and
javascript in php code causes page to display white
Hi All,
Odd one this, I've got the following code (below) which is a simple log in form. The
downloading a file as HTML
Hi.
I'm rather confused with forcing a download. I just want to save dynamic content (from $_SESS
unexpected T_SL without a shift left token
Nothing too see here, I'm an idiot and resolved the problem.
ctype() validation - allowing illegal characters
Hello,
I use ctype() to filter and validate a user form. However, I am trying to allow certain c
Login Script Issues
I am using a script I got from http://phpsense.com/php/php-login-script.html in order to allow peopl
INSERT for date range
Hi all
I have the following table
Code: [Select] `date` date
`day` int(2)
`
MS Access data into a html table
Hi everyone, I am quite a novice at php but I have created some helpful scripts that fetch data
f
A Few Questions
Hi, I want to ask a few questions that I can't seem to find..
1) I'm creating a "shortcu