title: Reading text from XML nodes using Python's libxml2
body: <p>I am a first time <code>XPath</code> user and need to be able to get the text values of these different elements.. for instance <code>time</code>, <code>title</code>, etc.. I am using the <code>libxml2</code> module in Python and so far have not had much luck getting just the values of the text I need. The code below here only returns the element tags.. i need the values.. any help would be GREATLY appreciated!</p>
  
  <p>I'm using this code:</p>
  
  <pre><code>doc = libxml2.parseDoc(xmlOutput)
  result = doc.xpathEval('//*')
  </code></pre>
  
  <p>With the following document:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8" ?&gt;
  &lt;!DOCTYPE SCAN_LIST_OUTPUT SYSTEM "https://qualysapi.qualys.com/api/2.0/fo/sca/scan_list_output.dtd"&gt;
  &lt;SCAN_LIST_OUTPUT&gt;
  &lt;RESPONSE&gt;
  &lt;DATETIME&gt;2012-01-22T01:21:53Z&lt;/DATETIME&gt;
  &lt;SCAN_LIST&gt;
    &lt;SCAN&gt;
      &lt;REF&gt;scan/2343423&lt;/REF&gt;
      &lt;TYPE&gt;Scheduled&lt;/TYPE&gt;
      &lt;TITLE&gt;&lt;![CDATA[customer 1 5/20/2012]]&gt;&lt;/TITLE&gt;
      &lt;USER_LOGIN&gt;user1&lt;/USER_LOGIN&gt;
      &lt;LAUNCH_DATETIME&gt;2012-02-21T04:11:05Z&lt;/LAUNCH_DATETIME&gt;
      &lt;STATUS&gt;
        &lt;STATE&gt;Finished&lt;/STATE&gt;
      &lt;/STATUS&gt;
      &lt;TARGET&gt;&lt;![CDATA[13.3.3.2, 13.8.8.10, 13.10.12.60, 13.10.12.11...]]&gt;&lt;/TARGET&gt;
    &lt;/SCAN&gt;
  &lt;/SCAN_LIST&gt;
  &lt;/RESPONSE&gt;
  &lt;/SCAN_LIST_OUTPUT&gt;
  </code></pre>