Hi, this is the content of my XML file:
<?xml version="1.0" encoding="ISO-8859-1"?>
<mainNode>
<sub time="08:00">
<status id="2">On</status>
<status id="3">Off</status>
</sub>
<sub time="13:00">
<status id="4">On</status>
<status id="7">On</status>
</sub>
<sub time="16:00">
<status id="5">On<...
Hello,
If have a following element in my XSL file:
<xsl:value-of select="replace(lower-case(@name), '_([a-z0-9])', '$1')" />
For example from 'get_polygene_lubricants' it makes 'getpolygenelubricants'.
What I want to do is to replace the first letter after '_' with
the uppercase variant of the letter. I googled, read documentation,
...
I understand that the name of selectNode/selectSingleNode methods actually suggests that they are designed to return a node, however maybe there is some other way or a setting available to enable XPath evaluator to return data of other types (that are also valid XPath results)
oDocument.selectSingleNode("'1'");
throws an error "Expr...
Imagine the following table:
-------------------------------------------------------------
ID | XML
-------------------------------------------------------------
1 | <Form><object ID="1" /></Form>
2 | <Form><object ID="2" /></Form>
3 | <Form><object ID="2" /></Form>
---------------------------------------------...
Hi,
To sum up, i'm a totally beginner in libxml and I have to use an existing source code. The main idea is to apply a first xpath expression to extract a set of nodes from an xml file. Then, for each node, the second xpath expression shall be applied to extract some values.
Existing source code is:
int xt_parseXmlResult(xmlDocPtr doc...
I'm trying to parse an Atom feed programmatically. I have the atom XML downloaded as a string. I can load the XML into an XmlDocument. However, I can't traverse the document using XPath. Whenever I try, I get null.
I've been using this Atom feed as a test: http://steve-yegge.blogspot.com/feeds/posts/default
Calling SelectSingleNode()...
I have a XSLT I've created to handle a particular xml document. However, now namespaces are being introduced in some, but not all of our documents. I'd like to use the same XSLT for these documents, however I'm having trouble modifying my stylesheet to be namespace agnostic.
It's been suggested previously to modify my xpaths to *[local...
Does anyone know of an existing means of creating an XML hierarchy programatically from an XPath expression?
For example if I have an XML fragment such as:
<feed>
<entry>
<data></data>
<content></content>
</entry>
</feed>
Given the XPath expression /feed/entry/content/@source I would have:
<feed>
<entry>...
What are the best XPath 2.0 Expression Evaluator for Eclipse?
Any other standalone that is worth saying?
...
Hi,
I am trying to create a 'AET' (Abstract Expression Tree) for XPath (as I am writing a WYSIWYG XSL editor). I have been hitting my head against the wall with the XPath BNF for the past three to four hours.
I have thought of another solution. I thought I could write a class that implements IXPathNavigable, which returns a XPathNaviga...
How would I find the node(s) with the max version from the following document:
<GateKeeperFiles>
<File>
<Name>GateKeeper.exe</Name>
<Major>2</Major>
<Minor>1</Minor>
<Build>1</Build>
<Revision>6</Revision>
</File>
<File>
<Name>GateKeeper.exe</Name>
<Major>1</Major>
<Minor>1</Minor>
<Build>1</Bui...
What are the currently available XSLT processors supporting XPath 2.0 standard?
...
I inherited some code that is using XPath for which I am a novice. I have it now so that it loads the document, but when the document.selectPath(queryPath) it always fails with the following error:
java.lang.RuntimeException: Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on //
at org.apache.x...
I'm trying to use XPath to find all elements that have an element in a given namespace.
For example, in the following document I want to find the foo:bar and doodah elements
<?xml version="1.0" encoding="UTF-8"?>
<root xmlns:foo="http://foo.example.com">
<foo:bar quux="value">Content</foo:bar>
<widget>Content</widget>
<doodah ...
Hi,
I am using Xpath (and java) to extract information from some websites. However my problem is that since some of these websites are not well-formed, I cannot process them. Is there any way to avoid well-formedness check or alternatively specify tags that should'nt be checked for well-formedness?
Thanks
Rp
...
Is there a tool or browser plugin (not sure if Firebug can do this) that will let you open a web page and then using the tool/plugin to search using an xpath query and it will highlight the things on the screen that match your query?
...
Let's say I have an XML doc like this:
<books>
<book>1110</book>
<book>1111</book>
<book>1112</book>
<book>1113</book>
</books>
I'm trying to setup a condition that tests the value of the current node in the for-each, but I'm doing something wrong:
<xsl:for-each select="/books/book">
<xsl:if test=".[='1112']">
...
Its a .vbproj and looks like this
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>15a7ee82-9020-4fda-a7fb-85a61664692d</ProjectGuid>
all i want to get is the ProjectGuid but it does not work when a namespace i there...
Dim xmlDoc As New XmlDocum...
Hi,
I was wondering if there was any way to access common parent node using Xpath.
<outer>
<main>
<a><b> sometext </b></a>
<c><d> sometext2 </d></c>
</main>
</outer>
I have the text nodes sometext and sometext2. is there a way i can access main (common parent) of these two nodes? I do not know the layout of the...
example...
<xml>
<level1>
<level2>
<![CDATA[ Release Date: 11/20/09 <br />View Trailer ]]>
</level2>
</level1>
</xml>
when I use inFeed.getXpath().evaluate("xml/level1/level2", myNodeList);
I get "Release Date:11/20/09 View Trailer"
I was under the impression that the whole point of CDATA is that it preserves whatever mumbo jumbo yo...