Hello I would like to know how to get the info from an xml file when the tag contains more than one attribute like in this case: I send request to get backupSessions I get xml file with a lot of ref tags , how to select one ref and its link tags based on the name attribute in the ref tag:
<Ref Href="http://172.19.11.128:9399/api/backupSes ... f018ed5c3d" Type="BackupJobSessionReference" UID="urn:veeam:BackupJobSession:6fe627e2-59ad-4602-bd0c-2af018ed5c3d" Name="Backup Job 1@2014-04-10 12:11:04">
<Links>.....</Links>
</Ref>
-
- Influencer
- Posts: 23
- Liked: 1 time
- Joined: Mar 21, 2014 3:06 pm
- Full Name: sirine chadly
- Contact:
-
- Novice
- Posts: 9
- Liked: 3 times
- Joined: Jun 18, 2013 10:06 am
- Full Name: Alexey Rostovskiy
- Contact:
Re: parse data from xml response
Hello
Actually it depends on what you using are to parse data.
But typically you should choose node (first, last, all of them) and get attribute you need (Name, Href, UID, etc).
Actually it depends on what you using are to parse data.
But typically you should choose node (first, last, all of them) and get attribute you need (Name, Href, UID, etc).
-
- Influencer
- Posts: 23
- Liked: 1 time
- Joined: Mar 21, 2014 3:06 pm
- Full Name: sirine chadly
- Contact:
Re: parse data from xml response
any example with php?
-
- Novice
- Posts: 9
- Liked: 3 times
- Joined: Jun 18, 2013 10:06 am
- Full Name: Alexey Rostovskiy
- Contact:
-
- Novice
- Posts: 9
- Liked: 3 times
- Joined: Jun 18, 2013 10:06 am
- Full Name: Alexey Rostovskiy
- Contact:
Re: parse data from xml response
Sirine, you can also check examples with php in “(EM install dir)\samples" folder: there are 6 typical action like StartJob, AddVmToJob, etc, plus generated php classes from xsd.
Who is online
Users browsing this forum: No registered users and 2 guests