google protocol buffers vs json vs XML [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for … Read more

XPath: Get parent node from child node

I need get the parent node for child node title 50 At the moment I am using only //*[title=”50″] How could I get its parent? Result should be the store node. <?xml version=”1.0″ encoding=”utf-8″?> <d:data xmlns:d=”defiant-namespace” d:mi=”23″> <store d:mi=”22″> <book price=”12.99″ d:price=”Number” d:mi=”4″> <title d:constr=”String” d:mi=”1″>Sword of Honour</title> <category d:constr=”String” d:mi=”2″>fiction</category> <author d:constr=”String” d:mi=”3″>Evelyn Waugh</author> … Read more

XML Schema minOccurs / maxOccurs default values

I’m wondering how the XML Schema specification handles these cases: <xsd:element minOccurs=”1″ name=”asdf”/> No maxOccurs given -> Is this the cardinality [1..1]? <xsd:element minOccurs=”5″ maxOccurs=”2″ name=”asdf”/> I suppose this is simply invalid? <xsd:element maxOccurs=”2″ name=”asdf”/> Is this the cardinality [0..2] or [1..2]? Is there an “official” definition on how the XML Schema spec handles these … Read more

XPath to select element based on childs child value

Trying to select an element based on the value of one of it’s childrens childrens Thinking the following but not working, appreciate any help, thanks ./book[/author/name=”John”] or ./book[/author/name text() = ‘John’] Want all books where the author name=”John” Xml file <list> <book> <author> <name>John</name> <number>4324234</number> </author> <title>New Book</title> <isbn>dsdaassda</isbn> </book> <book>…</book> <book>…</book> </list> 1 Answer … Read more

How can I escape “&” in XML? [duplicate]

This question already has answers here: How do I escape ampersands in XML so they are rendered as entities in HTML? (10 answers) Closed last year. I write <string name=”magazine”>Newspaper & Magazines</string> in file strings.xml. But the compiler says: The entity name must immediately follow the ‘&’ in the entity reference. strings.xml /OOReaderWidget/res/values line 9 … Read more

XML attribute vs XML element

At work we are being asked to create XML files to pass data to another offline application that will then create a second XML file to pass back in order to update some of our data. During the process we have been discussing with the team of the other application about the structure of the … Read more

XML Schema (XSD) validation tool? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers. Want to improve this question? Update the question so it’s on-topic for Stack Overflow. Closed 6 years ago. Improve this question At the office we are currently writing an application that will generate XML files against a schema that we … Read more

Are SVG parameters such as ‘xmlns’ and ‘version’ needed?

In about half of the svg examples I see on the internet, the code is wrapped in plain simple <svg></svg> tags. In the other half, the svg tags have lots of complicated attributes like this: <svg xmlns=”http://www.w3.org/2000/svg” version=”1.1″ xmlns:xlink=”http://www.w3.org/1999/xlink”> My question is: is it ok to use the simple svg tags? I’ve tried playing around … Read more