xml

Checking that at least 2 of the 5 lines exist on an address in XSL 1.0 before outputing the address node

I'm trying to create an address that validates against a schema set in stone, it requires that at least 2 of the 5 lines have been entered. Only show address node if at least two of the five lines are available. Is there a way I can check this using XSL The input looks like this: <Services Street="1 The Road " ExtraAddress="The Stre...

How to achieve this table structure using xslt

Hi All, I am facing one problem while writing one xslt: xml: <students> <studentDetails tag="to" id="1" fname="AA"/> <studentDetails tag="mo" id="2" fname="BB"/> </students> writing a xslt i have to convert it into HTML: <table> <tr> <th>to</th> <th>mo</th> </tr> <tr> <td>1</td> <td>2</td> ...

Custom configuration for JBoss applications?

I've built a simple alert monitor to display the health of various applications. This is configured by XML, as each monitor instance needs to show different metrics. An example configuration may be: <machine> <monitors> <check type="connectivity" name="Production Server"> <property key="host" value="ops01.corp" /> <ala...

Pagination problem

Currently I have some xml documents which are converted via xsl into html. The html is converted via abcpdf into a pdf document. The content of the pages is dynamic. A page is represented by a div tag, however the amount of content going in could in fact be 3 pages long & I need some pages to have a header and a footer inserted and some ...

Java HTTP post for XML SOAP message

How to expose / publish services using Java HTTP post for XML SOAP message. What are all steps need to follow. I did googling but haven't found any thing about exposing / publishing services. ...

Daily server-side caching of 10,000 Google Maps geocoder responses

I'm currently looking into methods of implementing server-side caching of roughly 10,000 Google Maps geocoder responses in a J2EE web application. Since Google limits the number of geocoding requests to 15,000 per day, I need a method to store my requests for 24 hours. The requests originate from an XML file that sits on the server, and ...

C#, how to extract an XML element from XML file using XPath?

I have the following XML document <MimeType> <Extension>.aab</Extension> <Value>application/x-authorware-</Value> </MimeType> <MimeType> <Extension>.aam</Extension> <Value>application/x-authorware-</Value> </MimeType> The whole document contains about 700 entries, how can I extract a single Mime Type elemen...

How to merge xml parent nodes base on element value in two nodes?

I am new to XSLT. I want to combine two nodes base on the same element value. Here is input file. <data> <node> <itemA element1="a" element2="x"> <itemBs><other elements with element2=x></itemBs> </node> <itemA element1="a" element2="y"> <itemBs><other elements with element2=y></itemBs> <node> <itemA element1...

LoadXML Problem C#

I have a code snippet : XmlDocument doc = new XmlDocument(); try { doc.LoadXml(xmlPath); } catch (Exception ex) { string exMessage = ex.Message; } The XML looks like this <?xml version="1.0" encoding="UTF-8"?> <MimeTypes> <MimeType> <Extension>.3dm</Extension> ...

how do you parse comma-separated-values (csv) with awk?

I am trying to write an awk script to convert a CSV formatted spreadsheet into XML for Bugzilla bugs. The format of the input CSV is as follows (created from an XLS spreadsheet and saved as CSV): tag_1,tag_2,...,tag_N value1_1,value1_2,...,value1_N value2_1,value2_2,...,value2_N valueM_1,valueM_2,...,valueM_N The header column represe...

Saving form elements properties to XML (Save control state)

Hello, I have been using in some projects a xml library for my settings saving, how it worked was like this : saveSettings(Control control, XmlConfig config, string controlName) It would then search all the controls inside that one (recursively), calling itself each time it found a new control, etc, and saving all their info to a xml ...

Is there a way to comment code in Notepad2?

Notepad2 is by far my most favorite editor to do quick edits to HTML, XML, etc... One thing that would be absolutely awesome is the ability to highlight a chunk of XML and comment it out or uncomment it. Is this possible with Notepad2? ...

WPF button Keypad contents generation from xml file

Hello all Can someone help? I have been sruggling to find information on how to populate the contents of each button in a wpf keypad that I've generated. It automatically generates the contents with the grid positon numbers. I need to fill the contents of each button from a node in a xml file. Thanks in advance. ...

Generic XML sorting via XSLT applied by Java?

Basically, I want an exact copy of the XML, except I'd like to sort certain nodes by their ID attribute. Not all elements with the ID attribute should be sorted. I've kludged together a working stylesheet, but it requires me to hard-code the <xsl:apply-template>'s in for all sibling nodes to the nodes I'm sorting on. I've no formal ...

XSLT transform replacing a tag that appears periodically through document

I have an xml document that I am transforming with xslt into an xsl-fo document. I have this tricky problem I've been trying to track down a solution to for a long time... In my source xml I have a few tags interspersed throughout. I want to format these as underline in the resulting document, however I have not been able to do so. I'...

How can I get content using XML::Twig?

My aim is that start_tag_handler (see below) get the apps/title content when it finds an apps/title tag (see sample XML below). And end_tag_handler gets the apps/logs content when it finds an apps/logs tag. But instead this code returns null and exits. This is the Perl code for parsing (using XML::Twig)###: #!/usr/local/bin/perl ...

Gadget, Write Unicode Data in XML

Hello I want in Gadget, Write Unicode data in XML File(I use UTF-8 to encode the XML document). for Write to XML, Use " fso = new ActiveXObject("Scripting.FileSystemObject"); ". But after Write, data not Unicode. In Addition, I need Data as Unicode. Thanks ...

.xml document downloadable?

Hello. I have this .xml file http://www.anitard.org/layouts/blogger_layouts/spicenwolf/spice_and_wolf_www.anitard.org.xml When i make a link to this in my website you will try to view that document, but that is not possible. How do i make it downloadable? So when i click on my link the .xml document will request to download it. ...

CakePHP XML view file

I would like to set CakePHP framework to allow page rendering when view file does not exist. I have all the definition set on layout and do not need extra empty files. Thanks! ...

RegExp to unwrap XML CDATA multiline text that has <br>'s in it?

Anyone know of a good reg exp that can do this, optimally in one go? It needs to remove whitespace at begin/end of each line, remove LFs and CRs and replace with a single space but if there's a <br> (or <br/>) at the end of the line it should not add a space. I'd need this in a JavaScript conform regexp. ...