Re: [PHP] Newbie Question - Parse XML with PHP...

[email protected] (Matijn Woudt)
Newsgroups php.general
Message-ID <CAC_gtuN8RHOwCnsTqwwGS5ucYtkiVuzSjPJOGgoF15Ua-CFvHw@mail.gmail.com>
On Sat, Apr 20, 2013 at 12:51 AM, dealTek <[email protected]> wrote:

>
> On Apr 19, 2013, at 3:32 PM, tamouse mailing lists <
> [email protected]> wrote:
>
> >>
> >> page1.php is sending out to credit card company - getting processed -
> then coming back to the *same page1.php* with the XML data listed below...
> >
> > Please expand what you mean by "sending out" and "coming back" - is
> > this a REST or SOAP API call? In that case, the response body is
> > likely to be the XML.
> >
> >>
> >> - so I'm not going to some other page to get it - it is coming to me to
> the same page I am on..........
> >>
> >> so - after the XML result comes in - I need to assign the php to the
> XML somehow...
> >
> > How do you recognize the "XML result com(ing) in" ?
> >
>
> Hi tamouse,
>
> with my untrained eye - it appears that this  is what is 'sending out'
>
>
>  $data = sendXMLviaCurl($xmlRequest,$gatewayURL);
>
>
> and this might be what is 'responding back' on the same page
>
>
>     $gwResponse = @new SimpleXMLElement((string)$data);
>
>
> you can see these lines towards the bottom at - // Process Step Three...
>
>
Why did you prefix this with @? This way your hiding the real error that is
probably the answer to why it is not working.

- Matijn
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.