我如何知道父節點的名稱說我在標籤=「襯衫」,我如何知道它的父母是「FG」的父母是john_carter。難道是知道(在minidom命名)xml python解析獲取父節點名稱:minidom
-90 可能。 。 。
<Object type="Layer" id="6" label="FG" expanded="True">
<Properties>
<Property id="blur" constant="True">
<Value>0</Value>
</Property>
.
.
.
<Property id="objects" expanded="True" constant="True">
<Object type="Layer" id="7" label="john_carter">
<Properties>
<Property id="blur" constant="True">
<Value>0</Value>
</Property>
.
.
.
<Property id="objects" expanded="True" constant="True">
<Object type="Layer" id="8" label="shirt" selected="True">
<Properties>
<Property id="blur" constant="True">
<Value>0</Value>
</Property>
.
.
.
.
.
.
.
.
.
.
.
.
發佈示例XML時,如果它是有效的XML,它將很有幫助。 – MattH