similar to: Quick XPath question (REXML)

Displaying 20 results from an estimated 2000 matches similar to: "Quick XPath question (REXML)"

2007 Jan 23
1
assert_select issue
I''d like to do an assert_select where only ONE of the matching elements needs to match the :text. It seems counterintuitive to me to require them *all* to match, which precludes me from testing the existence of a particular tag (h1) with some particular text if other instances of the same tag exist. I know that I can narrow down the field by using more detailed selectors, but it sure
2006 Jun 24
1
Parsing XML with REXML problem
Why can it not find my object? What am i missing here? Here is my code: require ''rexml/document'' include REXML # classes to represent the objects and relationships in the xml file class Article attr_accessor :id, :post, :archive, :ntype, :head, :blurb, :body, :fblurb, :fimage, :att, :source, :copy, :brand end # the base parser class BaseXMLParser def initialize(filename)
2017 Apr 04
1
Re: [PATCH v5 09/10] mllib: add XPath helper xpath_get_nodes()
On Thursday, 23 March 2017 10:02:47 CEST Cédric Bosdonnat wrote: > This function will allow more OCAML-ish processing of xpath queries > with multiple results. s/OCAML/OCaml/ s/xpath/XPath/ > --- > mllib/xpath_helpers.ml | 9 +++++++++ > mllib/xpath_helpers.mli | 4 ++++ > 2 files changed, 13 insertions(+) > > diff --git a/mllib/xpath_helpers.ml
2009 Jun 10
2
add variable in xpath
hi , i cant succeed add variable in xpath (libxml) brand = "037" xpath = "//Root/Stk[@Category=''601'' and @Brand=#{brand}]" stack = node.find(xpath) i used #{brand} but doesnt work
2006 Dec 08
1
XML, XPATH in Centos?
What built in utilities are there that can evaluate XML XPath statements in CentOS? Its needed to grab certain info from <a href="some.html">some</a> from a page with a python, perl or shell script. Hints on what to use would be appreciated. Chris -------------- next part -------------- An HTML attachment was scrubbed... URL:
2010 Aug 05
7
Search large XML file -- REXML slower than a slug, regex instantaneous
Got a question hopefully someone can answer - I am working on functionality to match on certain nodes of a largish (65mb) xml file. I implemented this with REXML and was 2 minutes and counting before I killed the process. After this, I just opened the console and loaded the file into a string and did a regex search for my data -- the result was almost instantaneous. The question is, if I can get
2017 Oct 29
2
A query language for LLVM IR (XPath)
Hi, sometimes when dealing with LLVM IR getting to a desired point of the code is a bit cumbersome, in particular if you're instrumenting existing code. A lot of nested loops and if checks. Maybe all of this could be avoided by employing a query language. Since an LLVM module can be seen as a sort of tree with attributes, I think that reusing an existing query language for XML would be
2017 Oct 31
2
A query language for LLVM IR (XPath)
As much as I'm not a fan of most XML things, this application of XPath is *inspired*. This would be a great testing/query tool for tests. It would also be a great way to prototype passes. Looking forward to seeing something like this in llvm/tools/ ! Cheers > On 1 Nov 2017, at 04:00, Sean Silva via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > This is so cool! I once
2015 Nov 12
1
[PATCH] inspector: --xpath: Copy node to new document (RHBZ#1281577).
'virt-inspector --xpath' can segfault. When run under valgrind, it shows this error: ==2254== Invalid free() / delete / delete[] / realloc() ==2254== at 0x4C29D6A: free (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) ==2254== by 0x53BA198: xmlFreeNodeList (tree.c:3690) ==2254== by 0x53B9F65: xmlFreeDoc (tree.c:1247) ==2254== by 0x405BFA: do_xpath (inspector.c:808)
2009 Jun 23
1
How to find b entries using xPath?
We got all rows by: library(XML) doc = htmlParse('http://www.statcan.gc.ca/daily-quotidien/090520/t090520b1-eng.htm') rows = xpathSApply(doc, '//table/tbody/tr') The last row is: row_last = rows[15] row_last [[1]] <tr><td id="t1stub17" class="stub1 RGBShade"><b>Unsmoothed composite leading indicator</b></td>&#13; <td
2011 May 30
1
Need help reading website info with XML package and XPath
Hi, I'm looking for help extracting some information of the zillow website. I'd like to do this for the general case where I manually change the address by modifying the url (see code below). With the url containing the address, I'd like to be able to extract the same information each time. The specific information I'd like to be able to extract includes the homedetails url, price
2010 May 17
3
Writing a properly-formed custom type (configxml)
Please hold my hand. After studying the wiki, several unofficial pages, various mailing list entries, and the operation of the "iptables" type as found on the net, I have created a custom type, lovingly named ``configxml''''. It updates attributes on the first element matching a supplied XPath in a given XML file. The first use case is configuring Atlassian JIRA to use
2007 Sep 29
2
REXML - XML query only returning one (last) result
I''m really new to Ruby on Rails, and I''m trying to read an XML file with REXML. No matter what I try, I am only getting the last result returned from my query. I should be getting 365 results. Here is the code: include REXML require ''rexml/document'' require ''rexml/xpath'' class MakeFootprintController < ApplicationController def index
2006 Jun 26
0
DBI question. How do I load a database with data parsed from REXML?
I wrote a rexml script that parses rather big xml files (DOM parsing) and builds an object out of them. This is what it looks like after i parse the xml file and display the object: [#<Article:0xb79e7428 @brand="This is a story from ", @id=5337, @fblurb="burb", @ntype="news type here", @copy="Copyright \302\251 2006 ", @source="source",
2007 Aug 24
1
How to download any file using send_file() method
HI, I am directory listing and in that listing I have certain files and sub directories, now when I click on the files it should download that particular file but I am not able to accomplish it, and I have got to use send_file() method. In the send file Code shown below I have made use of the address of one of the files directly so when I click the link of any file it downloads it. THE CODE
2007 Apr 23
0
backgroundrb and REXML issue
Hi, I have an application that receives XML files, and then hands each one off to a backgroundrb worker to parse and store the info. Everything was working, until I needed to support a larger character set. So I added the following to the top of my XML files: <?xml version="1.0" encoding="ISO-8859-1"?> Adding this worked fine when I tested it without using
2006 Mar 10
2
Generating RSS 1.0
Hi All, I bought the ''beta book'' of Rails Recipes from pragprog and there''s a tutorial in there for producing RSS 2.0, i''d like to generate RSS (RDF) 1.0 though. Can anyone point in the right direction. I''ve had little luck finding detailed information on the ruby XML class. Thanks -- Posted via http://www.ruby-forum.com/.
2012 Apr 11
0
F5 SLB iRule - POP3 TLS Offload & Add Realm
Hey Guys, I figured someone might have use of this at some point. I've created an iRule for our F5 Load Balancer which performs the following tasks: - Appends STLS to the POP3 Capability list (it does this blindly, so expects the backend POP3 server to not return this) - Watches for the STLS command and initiates SSL negotiation with the client (leaves the connection to the
2008 Dec 04
3
Patch: Allow args with spaces
Hi, the first attached patch extends the argument parsing code to allow (shell like) spaces. A config like LABEL BIOSupdate KERNEL dmiselect.c32 APPEND "ESPRIMO P5925" "memdisk initrd=/dos/FSC-E5925.img raw" will result in args[]: ESPRIMO P5925 memdisk initrd=/dos/FSC-E5925.img raw instead of (current code): "ESPRIMO P5925" "memdisk
2008 Aug 19
6
redirect with application add
There are groups within our app that people can be invited too. If a user recieves an invite to a group and hasn''t yet added the application the filter chain ends up redirecting them to the main canvas page instead of the the group page directly. Is there a way to handle this if the user hasn''t installed the app, I tried redirect_back_or_default in one of my controllers but it