> Traceback (most recent call last):
> File "/home/mucip/ParseXML.py", line 14, in <module>
> xmlTag = dom.getElementsByTagName('tagName')[0].toxml()
> IndexError: list index out of range
>
Python dan pek anlamam ama, dom.getElementsByTagName('tagName') bu
metotdaki parametreye gönderilen değer 'tagName' mi?
Bahsi geçen XML dosyası şöyle başlıyor:
<?xml version="1.0" encoding="ISO-8859-9" standalone="no"?>
<?xml-stylesheet type="text/xsl" href="cif.xsl" ?>
<csv_data_records xsi:noNamespaceSchemaLocation="cif.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
source="cif.csv">
<record num="1">
<BKOD>0001</BKOD>
<SKOD/>
<NAME>T.C.MERKEZ BANKASI A.�.</NAME>
<CITY/>
</record>
<record num="2">
dom.getElementsByTagName('tagName') metodundaki 'tagName' 'record'
olarak değişmesi gerekiyor gibi geldi bana.
--
MCTS, H.Hüseyin GENÇER
_______________________________________________
Linux-programlama mailing list
[email protected]
https://liste.linux.org.tr/mailman/listinfo/linux-programlama
Liste kurallari: http://liste.linux.org.tr/kurallar.php