 |
Forums |
Admin Discussion Forums: help Start New Thread
| Message: 92062 |
 |
BY: Les Nightingill (lazylester) DATE: 2009-12-21 15:32 SUBJECT: LibXML find with namespace I would greatly appreciate any help with this noob question...
I'm using LibXML-Ruby to make a very small xml doc and then search for a node. The document is correctly generated, but I'm evidently missing something very basic because the search is not yielding any result. I have:
require 'rubygems'
require 'xml'
tmp_doc = XML::Document.new()
tmp_doc.root = XML::Node.new('a:frame')
tmp_doc.root["xmlns:a"]='http://bar/baz'
tmp_doc.root << XML::Node.new('a:table')
puts tmp_doc
puts tmp_doc.find("//a:table","a:http://bar/baz").length
The doc is printed but search result is 0
Can you help with the "find" statement, please? Thanks in advance. | |
Thread View
| Thread |
Author |
Date |
 |
LibXML find with namespace | Les Nightingill | 2009-12-21 15:32 | |
Post a followup to this message
|
 |