Note that there are some explanatory texts on larger screens.

plurals
  1. POLooping through a SOAP response
    primarykey
    data
    text
    <p>I have created an application that sends out a SOAP request and gets a response back. This is working fine but I am having trouble looping through all the individual results in order to organize them into an array. Here is the response:</p> <pre><code>stdClass Object ( [FITgymlistResult] =&gt; stdClass Object ( [FITgym] =&gt; Array ( [0] =&gt; stdClass Object ( [GYMGUID] =&gt; 45124542-bca5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Belfast [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; belfast@fitspace.co.uk ) [1] =&gt; stdClass Object ( [GYMGUID] =&gt; aece7776-bca5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Bournemouth [Addressline1] =&gt; St Paul's Road [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; Bournemouth@fitspace.co.uk ) [2] =&gt; stdClass Object ( [GYMGUID] =&gt; 8eaa258e-bca5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Bradford [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; Bradford@fitspace.co.uk ) [3] =&gt; stdClass Object ( [GYMGUID] =&gt; 935bfdca-bca5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Islington [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; holloway@fitspace.co.uk ) [4] =&gt; stdClass Object ( [GYMGUID] =&gt; fe104008-bda5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Lincoln [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; lincoln@fitspace.co.uk ) [5] =&gt; stdClass Object ( [GYMGUID] =&gt; ff3cd339-bda5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Mitcham [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; Mitcham@fitspace.co.uk ) [6] =&gt; stdClass Object ( [GYMGUID] =&gt; 496e8149-bda5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Nottingham [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; Nottingham@fitspace.co.uk ) [7] =&gt; stdClass Object ( [GYMGUID] =&gt; 48f26656-bda5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Sheffield [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; Sheffield@fitspace.co.uk ) [8] =&gt; stdClass Object ( [GYMGUID] =&gt; 1c136968-bda5-e211-8f4a-00155d007722 [GYMNAME] =&gt; Woolwich [Postcode] =&gt; [Phone] =&gt; [Email] =&gt; Woolwich@fitspace.co.uk ) ) ) </code></pre> <p>)</p> <p>What would be the best and quickest way to loop through each individual item in this response? Thanks</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload