Posted to tcl by de at Wed Feb 25 17:59:42 GMT 2015view raw

  1. package require tdom
  2.  
  3. set doc [dom parse [::tDOM::xmlReadFile "path/to/you/xml"]]
  4. foreach channel [$doc selectNodes //channel] {
  5. puts "title: [$channel selectNodes string(title)]"
  6. puts "link: [$channel selectNodes string(link)]"
  7. }
  8.