i'm including an alternate stylesheet for iPhone/iTouch devices. Initially i wanted to simply use the handheld media type:
<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type='text/xsl' href='/css/homepage_handheld.xsl' media='handheld'?>
<?xml-stylesheet type='text/xsl' href='/css/homepage.xsl' media='all'?>
which i add to t...
Sometimes XML files needs to be stored in some VCS. Such files are often edited using GUI tools which can reorder the elements each times as they want.
Also VCS merging is usually line-oriented, and often XML files either looks likes one long line or fully indented like
<foo>
<bar>
<name>
n3
</name>
...
[a-zA-Z_:]([a-zA-Z0-9_:.])*
Would this do?
...
Hi,
I need to come up with some kind of rules engine, where I can specify validation rules for specific xml files. Then the rules are read in and asserted against the xml.
Whats the best way? Is it XPath, or XQuery, or XSL, or XSD even? Or maybe even XMLUnit?
I'll need to do stuff like detect when certain attibutes are different from...
I'm using the SyndicationFeed helper class to request and parse a Twitter RSS feed. I just discovered that I'm actually using the Twitter REST API by requesting RSS feed data. There's a limit to the number of requests per hour and that limit is actually returned in a response header called X-RateLimit-Remaining. I'd like to get that numb...
Can you nest xsl:if within nested xsl:when, for example:
<xsl:choose>
<xsl:when test="param/@id = '1' " >
<xsl:if test="param/value = 'XML' ">
<xsl:when test="param/@id = '2' ">
<xsl:if test="param/value = 'HTTP' ">
<xsl:when test="param/@id = '3' ">
...
Hi, I don't really know anything about this, but I'm learning how to write Android apps. I'm working through the Hello, World | Android Developer Tutorial, and was doing fine until I tried the XML code. I copy/pasted the code given in the tutorial into the layout file as instructed. But when I attempted the next step (open strings.xml...
Hi there,
I have three xml files of similar structure and I would like to use an xpath-expression to extract all matching nodes in these files and write them to a thrid one.
Do you know a good tool to handle this?
I am thinking of something like
$supermagicxpathtool -x "//whoopdee" file1.xml file2.xml file3.xml > resultfile.xml
...
I have a form/calculator, which posts to itself some data, this data is then calculated by dispatching a servlet and the results are output as xml. The dispatcher code is shown below:
//create instance
ServletContext sc = this.getServletContext();
//create dispatcher
RequestDispatcher rd = sc.getRequestDispatcher("/ProCalcServlet");
rd...
In a Windows Form application, I'm trying to create a DataGridView with two columns: one for the key given by an XML element and one for the value of said XML element. This is my code so far:
this.myData = new DataGridView();
((System.ComponentModel.ISupportInitialize)(myData)).BeginInit();
myData.Location = new...
I'm knee deep in the nightmare that is RDFa implementation for product information and am curious if anyone out there can provide some insight.
Google flat out say's not to hide information just for the sake of providing data to machines unless it is information that is specific to machines. I could not find any information on the subje...
Hello,
I am new to programming so bear with me. I have many XML documents that look like this:
File name: PRIDE_Exp_Complete_Ac_10094.xml.gz
<ExperimentCollection version="2.1">
<Experiment>
<ExperimentAccession>1015</ExperimentAccession>
<Title>Protein complexes in Saccharomyces cerevisiae (GPM06600002310)</Title>
<ShortL...
Hi!
I need to make a request to an API, using REST (POST method) in PHP.
But the data needs to be in XML format. How can I send REST requests with XML data?
Thank you!
...
How do I get radar images to a .Net program using this service: http://www.nws.noaa.gov/forecasts/xml/
I literally have no clue where to start. If someone could provide some sample code or maybe direct me to a tutorial of some kind that would be awesome.
Thanks Alot
...
I know I have done this before, but it isn't working today, nor can I find anywhere that explains how to do it. It could be my lack of sleep, but I suspect gremlins.
I have an XML document and a directory full of XSD's that define it. How do I set the Visual IDE up to notify me of validation failures, and then provide an intellisens...
Hi,
Can someone recommend an xml beautifier online, something just like jsonlint.org?
Thanks
...
I am using an RSS feed as a data source. I've adjusted how I retrive the data to use the WebClient.DownloadStringAsync method. Before I was using XmlReader.Create method. I'm then using the results as a data source to bind to a TextBlock in WPF.
Since I made the change when I display my results all the special encoded characters are app...
Hi all, first time poster. Please be gentle.
This topic may be similar to several other questions out there, but as far as I can see this is a unique problem I'm trying to solve. FWIW, I'm primarily a designer; I'm dangerous with Flash and HTML and CSS, but a bit in the weeds with everything else. From searching around, I appear to be...
Is there any way to print empty elements like <tag></tag> rather than <tag /> using org.w3c.dom? I'm modifying XML files that need to be diff'ed against old versions of themselves for review.
If it helps, the code that writes the XML to the file:
TransformerFactory t = TransformerFactory.newInstance();
Transformer transformer = t.newTr...
I tried opening xml file using both the ways, but only the latter part worked when I tried to use xpath.
eg., doc = as in title;
doc.xpath('//feed/xyz'), worked only when I open the file using parse method.
One thing I noted was, the object when I open using XML:: is Nokogiri::XML::Document, while the latter one was Nokogiri::HTML...