I'm using python to parse a XML file but I have a problem. I'm sure there is a way to solve it but I'm new on python and parsing xml...
So here a example of xml :
<TeamData Ref = "1">
<Goal></Goal>
<Goal></Goal>
<Goal></Goal>
<Goal></Goal>
</TeamData>
<TeamData Ref = "2">
<Goal></Goal>
<Goal></Goal>
<Goal></Goal>
<Goal></Goal>
</TeamData>
I want to store my element goal in two part in function of the team ref... How would I do that ? Because I tried :
for iterators in child.iter("TeamData"):
something_to_store(iterators.tag)
But I have the list of all the 8 goals without difference in function of the teamdata ref !