Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6803967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T19:24:32+00:00 2026-05-26T19:24:32+00:00

Is there anyone who has done some integration with securetrading using stapi? I currently

  • 0

Is there anyone who has done some integration with securetrading using stapi? I currently am trying to integrate paypal and have the following xml response being returned to my console:

<responseblock version="3.67"> 
<requestreference>X3556qikiki32155</requestreference> 
<response type="ORDERDETAILS"> 
<merchant> 
<merchantname>test account</merchantname> 
<orderreference>aaaa123</orderreference> 
</merchant> 
<customer> 
<town>PAYPAL City</town> 
<street>MORE STREET</street> 
<name> 
<last>PayPalShipToName</last> 
</name> 
<premise>1 PayPalStreet</premise> 
<country>US</country> 
<ip>127.0.0.1</ip> 
</customer> 
<transactionreference>412-32323222-2323235284</transactionreference> 
<billing> 
<name> 
<last>PAYPALLastName</last> 
<first>Andr©©</first> 
</name> 
<country>GB</country> 
<email>paypal.email@example.com</email> 
</billing> 
<paypal> 
<addressstatus>Confirmed</addressstatus> 
<payerstatus>verified</payerstatus> 
<payerid>c6e9460f5232uijijd2dweqa6591pid</payerid> 
</paypal> 
<live>0</live> 
<error> 
<message>Ok</message> 
<code>0</code> 
</error> 
<timestamp>2011-11-14 22:36:50</timestamp> 
<settlement> 
<settleduedate>2011-11-14</settleduedate> 
<settlestatus>0</settlestatus> 
</settlement> 
<operation> 
<parenttransactionreference>42332-323232-52332279</parenttransactionreference> 
<accounttypedescription>ECOM</accounttypedescription> 
</operation> 
</response> 


<response type="AUTH"> 
<merchant> 
<merchantname>test account</merchantname> 
<orderreference>aa72323</orderreference> 
</merchant> 
<transactionreference>4qwdwd-w323232-34fd5285</transactionreference> 
<billing> 
<amount currencycode="GBP">19995</amount> 
<payment type="PAYPAL"/> 
</billing> 
<authcode>41685-dwww233qwd</authcode> 
<timestamp>2011-11-14 22:36:50</timestamp> 
<settlement> 
<settleduedate>2011-11-14</settleduedate> 
<settlestatus>0</settlestatus> 
</settlement> 
<live>0</live> 
<error> 
<message>Ok</message> 
<code>0</code> 
</error> 
<acquirerresponsecode>None</acquirerresponsecode> 
<operation> 
<parenttransactionreference>4233-dae3232-5232284</parenttransactionreference> 
<accounttypedescription>ECOM</accounttypedescription> 
</operation> 
</response> 
</responseblock> 

basically once I get the response I am using the following to get the values from the xml:

$p = xml_parser_create();
xml_parser_set_option($p, XML_OPTION_CASE_FOLDING, 0);
xml_parser_set_option($p, XML_OPTION_SKIP_WHITE, 1);
xml_parse_into_struct($p, $return_xml, $vals, $index);
xml_parser_free($p);
print_r($vals);

but when I print_r the values I only get the values from the ORDERDETAILS block being displayed and not the ones from the auth block.

Any help with this would be appreciated.

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T19:24:33+00:00Added an answer on May 26, 2026 at 7:24 pm

    I wrote a PHP class to wrap SimpleXML, so that it’s a little clearer to use:

    https://github.com/homer6/altumo/blob/master/source/php/Xml/XmlElement.md

    $xml_element = new \Altumo\Xml\XmlElement( $response_contents );
    var_dump( $xml_element->xpath('response[@type=AUTH]/merchant/merchantname') );
    
    string(12) "test account"
    

    See: http://www.w3schools.com/xpath/xpath_syntax.asp for more xpath examples.

    Hope that helps…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there anyone who has used or looked into using Jitterbit as well as
Is there anyone who knows this? I have been trying this for the last
Is there anyone who has already tried to use the Microsoft Bing translator web
Is there anyone who have encountered Processing Dirty Regions error in MyEclipse? Actually everytime
Is there anyone who knows how to destroy a javascript (jquery) function? I'm using
Anyone who's tried to study mathematics using online resources will have come across these
I've done my SO and Google research, and haven't found anyone who has tackled
is there anyone who makes use of the Microsoft Open XML SDK 2.0 for
Anyone out there who knows what are the differences between BasicRenderEngine and LazyRenderEngine?
Is there anyone working solo and using fogbugz out there? I'm interested in personal

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.