xml

Convert xsd to ruby classes

Is there an analog of xsd tool from .NET framework in ruby, to create classes for serialization data to xml with appropriate xsd. I've found xsd2ruby from soap4r, but there is no documentation. And rxsd, that seems not works. ...

How to merge two XML files in classic ASP?

Hi! I'm using classic ASP in my project. I want to merge two XMLs together. How do I do this? Below is my sample code: XML 1 <CATALOG> <CD> <TITLE>1</TITLE> <ARTIST>Bob Dylan</ARTIST> <COUNTRY>USA</COUNTRY> <COMPANY>Columbia</COMPANY> <PRICE>10.90</PRICE> <YEAR>1985</YEAR> </CD> <CD> <TITLE>2</TITLE> <ARTIST>Bon...

Check if XML-node has attribute with Linq C#?

How can I check and see if a node actually has a certain attribute? I have an XML-file containing several nodes looking like this: <Field From="OldString" To="NewString" /> So far so good. The problem is that this structure is about to be changed to that some nodes will look like this: <Field From="OldString" To="NewString" PrefixVa...

how jquery parse xml from another xml??

hi,,, please help me to parse xml from another xml... i have this xml named browser.xml <tree> <root name="SA" hidden="yes"> <folder name="Diagram"> <folder name="Activity" refreshURL="diagram_activity.xml"></folder> <folder name="Business Process" refreshURL="diagram_business_process.xml"></folder> </folder> <folder name="Other"> <fo...

Webservice proxy class generation

I include the below xsd file: <?xml version="1.0" encoding="utf-8"?> <xs:schema xmlns="http://www.xxxx.com/schemas/2005/06/messages" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://www.xxxx.com/schemas/2005/06/messages" xmlns:xs="http://www.w3.org/2001/XMLSchema"&gt; <xs:include schemaLocation...

advanced xml? multi level .. php parsing

hi my knowledge of xml and php is somewhat basic but have been able to parse a simple xml document (one level) ~ <numbers> <number>1</number> <number>2</number> </numbers> i'm attempting to parse an xml document from a website providing the latest market prices for gold bullion. I think i'm going to need a paid professional but...

compact XSLT code to drop N number of tags if all are null.

This is my input xml: <root> <node1/> <node2/> <node3/> <node4/> <othertags/> </root> The output must be: <root> <othertags/> </root> if any of the 4 nodes isn't null then none of the tags must be dropped. example: <root> <node1/> <node2/> <node3/> <node4>sample_text</node4> <othertags/> </root> ...

Error: "Input is not proper UTF-8, indicate encoding !" using PHP's simplexml_load_string

I'm getting the error: parser error : Input is not proper UTF-8, indicate encoding ! Bytes: 0xED 0x6E 0x2C 0x20 When trying to process an XML response using simplexml_load_string from a 3rd party source. The raw XML response does declare the content type: <?xml version="1.0" encoding="UTF-8"?> Yet it seems that the XML is not really ...

Repeatedly querying xml using python

I have some xml documents I need to run queries on. I've created some python scripts (using ElementTree) to do this, since I'm vaguely familiar with using it. The way it works is I run the scripts several times with different arguments, depending on what I want to find out. These files can be relatively large (10MB+) and so it takes r...

How to exclude an enumeration value in XML file using XSD?

Is it possible to specify the value of a tag or attribute should not be like some_value ? I have a strange requirement, where the xsd isn't aware of the values being sent to it. The value of that particular tag can be a string with any value except one value ( say data_migration). The sender should be acknowledged with the error, if t...

Avoiding Redundancies in XML documents

I was working with a certain XML where there were no redundancies <person> <eye> <eye_info> <eye_color> blue </eye_color> </eye_info> </eye> <hair> <hair_info> <hair_color> blue </hair_color> </hair_info> </hair> </person> As you can see, the sub-tag eye-color makes ref...

reciving an Element object from rhino when using e4x

hi, i have a java object called myObject with function foo(Element e) that i am binding to the rhino context. in the script i am creating an XML using E4X, my question is how can i would pass this XML object as a parameter to foo? there is one solution to work with Strings something like: var data = new XML(); //Set data using E4X da...

How to make every word in the text clickable and send it to the script

I have a text for example "The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog." When i click on word i must get data from XML or from mysql about this word. How i can make every word active for click and se...

Insert XML with more than 4000 characters into a Oracle XMLTYPE column

Hi, I have an oracle table with a column from type "SYS.XMLTYPE" and a storage procudure which is doing the insert: (Short version): PROCEDURE InsertXML ( pXMLData IN LONG ) IS BEGIN INSERT INTO MY_TABLE (XML_DATA) VALUES(pXMLData); END InsertXML; I call this sp from my C# code with type "OracleType.LongVarChar". Now t...

Arranging MC that is called from XML backwards.

I'm loading my MC from XML backwards, and its separated by 10 per pages. When it's loaded to the stage it could not be arrange accordingly to grids. And when I click at other pages to let it run another 10 before the previous loaded XML object, it does not add in to the Array(I've clear off the array before reload the XML) private funct...

Regular expressions .net

I have the following function that I am using to remove the characters \04 and nulls from my xmlString but I can't find what do I need to change to avoid removing the \ from my ending tags. This is what I get when I run this function <ARR>20080625<ARR><DEP>20110606<DEP><PCIID>626783<PCIID><NOPAX>1<NOPAX><TG><TG><HASPREV>FALSE<HASPREV><H...

How to copy child nodes to another xml document?

Below is my xml XML1 <?xml version="1.0" encoding="ISO-8859-1" ?> <CATALOG> <CD> <TITLE>1</TITLE> <ARTIST>Bob Dylan</ARTIST> <COUNTRY>USA</COUNTRY> <COMPANY>Columbia</COMPANY> <PRICE>10.90</PRICE> <YEAR>1985</YEAR> </CD> <CD> <TITLE>2</TITLE> <ARTIST>Bonnie Tyler</ARTIST> <COUNTRY>UK...

Query an XmlDocument without getting a 'Namespace prefix is not defined' problem

I've got an Xml document that both defines and references some namespaces. I load it into an XmlDocument object and to the best of my knowledge I create a XmlNamespaceManager object with which to query Xpath against. Problem is I'm getting XPath exceptions that the namespace "my" is not defined. How do I get the namespace manager to see ...

remove the blank rows after i removed xml elements?

i removed some elements from a xml file with simpledom. the code: $this->xmlDocument->removeNodes("//entity[name='mac']"); here is the initial file: <entity id="1000070"> <name>apple</name> <type>category</type> <entities> <entity id="7002870"> <name>mac</name> <type>category</type> ...

Why is nodeName sometimes all-caps in javascript DOM?

So I have a DOM document that looks essentially like this <categories> <category id="1"/> <category id="2"/> </categories> This is how the document previews in Firebug, as I would expect. However, when I POST this to the server, I get <categories> <CATEGORY id="1"/> <CATEGORY id="2"/> </categories> Indeed, doc.docu...