xml

How to swap two XML elements in linq to xml

I want to swap two xml elements. How do i do this? Here is the code. I tried the solution here but it did not work for me after all. I want to swap the both elements. When I run the program the elements are not swapped but when I call ToList() it is swapped in the List but not swapped in the doc variable <template id="12"> <tabs> ...

How do I serialize DOM into XML using PHP?

I am attempting to send html data in a question form from my php web application to mechanical turk so a user can see the entire html document from an email to work with. I have had difficulty thus far. In the thread linked below, I attempted to parse the html data using html5-lib.php, but I think I'm still missing a step in order to c...

cannot find custom namespace in xml

Hi all, Could someone please help me out with this. I need to find the gml:pos namespace in the xml. But, very important! - in the $item part off the loop I really have no clue how to get this done. The namespace is in another custom namespace according to google-api docs. $feed = simplexml_load_string($feedXml); foreach ($feed->en...

Modify an attribute according to its data type c#

For a giving DB, I used CodeSmith to generate a text file that has the following values (TableName)([TableGUID]) (AttributeName).(AttributeType) for example CO_CallSignLists[e3fc5e2d-fe84-492d-ad94-3acced870714] SunSpots.smallint Now I parsed these values and assigned each to a certain variable for (int j = 0; j < newLst....

XML to JSON or To where to use it in .NET c#

How can I gather the data into c# from this xml? I get the data from :http://www.ecb.europa.eu/stats/eurofxref/eurofxref-daily.xml PS: I would like to get the currencies rates from a web service, bu I could not find a trustworthy web service, thats why I try from xml... <?xml version="1.0" encoding="UTF-8" ?> - <gesmes:Envelope x...

howto catch error on namespace or property not found in xml atom entry

Hi, I need some help please How is it possible to catch these errors, in a way that the program does not stop from running. $ns_gml=$item->children($namespace['georss'])->children($namespace['gml']); <b>Warning</b>: gpicasa::parseFeed() [<a href='/phpmanual/gpicasa.parsefeed'>gpicasa.parsefeed</a>]: Node no longer exists in <b>/home...

Android layouts

Hi I wounder if itpossible to have a view inside of a view, Iam going to have a toolbar on my android app,, and this toolbar is going to be shown in many activites, so I have xmlfile for each of the activites, and I wounder if should create an cml only for the toolbar. and then use ut in other xml files. How is that possible, so i don'...

XML reader error: unexpected character content exception while invoking webservice

Am trying to invoke a public web-service using a java client but am getting the following exception: deserialization error: XML reader error: unexpected character content: "<?xml version="1.0" ?> <rankedTermCandidates xmlns="http://www.nactem.ac.uk/xsd/termine" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLoc...

Flash MP3 player loop from XML playlist

I have an mp3 player based on the School of Flash code. When I click "next song" I need it to go to the next song, unless it's the last song in the playlist in which case it needs to go back to song number 1 in the playlist. The following code doesn't seem to do the trick, any ideas where I am going wrong? var songlist:XMLList; var cur...

Using XML as a datasource for Rails models

Is there a way to use external XML (or JSON) as a datasource for models in Rails. E.g. some models use the database for getting data, others "ping" external services for XML. ...

How do I parse this SOAP response in my iPhone application?

I am getting SOAP response and when parsing the response I am getting this: (As you can see from result which is currently stored as NSString is NSLoged itself contain xml format data) <Menus> <Table1> <Restaurant_Name>CHICK-FIL-A</Restaurant_Name> <Restaurant_id>2748</Restaurant_id> <Phone>(404) 371-1466</Phone> <billing_city>DECATU...

XPath query for a node

I should be doing something wrong. What is the XPath query for all nodes named "name" under display-name? I am using libxml2. <?xml version="1.0" encoding="UTF-8"?> <description xmlns="http://openoffice.org/extensions/description/2006" xmlns:d="http://openoffice.org/extensions/description/2006" xmlns:xlink="http://www.w3.org/1999/xlink...

Help with parsing / tranversing XML in JavaScript?

Hi. I need a little direction on how to parse this in JavaScript. I want to list the total number of buildings and in each building, the total number of tenants. My XML looks like this: <?xml version="1.0" encoding="UTF-8"?> <AppManager-response uri="/AppManager/xml/ListBuildings"> <result> <response method="ListBuildings...

Optimal Method to Minify an XML in C# 3.0

Coding Platform: ASP.NET C# I have an XML like this. <Items> <Map id="35"> <Terrains> <Item id="1" row="0" column="0"/> <Item id="1" row="0" column="1"/> <Item id="1" row="0" column="2"/> <Item id="1" row="0" column="3"/> <Item id="1" row="0" column="4"/> ...

What is the functionality of namespaces in xml documents?

Possible Duplicate: What are XML namespaces for? xmlns attribute of the xml element! ...

How do I stop Firefox opening XML docs with Google Reader?

I am trying to analyse the XML response from using the Youtube API as follows http://gdata.youtube.com/feeds/api/videos?q=dogs When I try this the browser gets taken to Google Reader, where a feed is loaded with the query results. But I want the actual XML document to be displayed in Firefox. How can I do this? Thanks for reading. ...

change xml format with xsl or other

can i use xsl or another thing similar to change this format <rr n="Address"> <tt> <j n="currentAddress">0</j> <j n="city">city</j> </tt> </rr> to this :- <Address> <tt> <currentAddress>0</currentAddress> <city>city</city> </tt> <Address> notice that i want the attribute value to become the element and r...

How to read remote XML via ASP?

Hello i have this XML <?xml version = '1.0' encoding = 'windows-1251'?> <ICBSProxy> <Message type=""> <Version>01.00</Version> <Parameter name="xICBSXPProxy.ProcessingDetail" id="1"> <Value>1250484</Value> </Parameter> <Parameter name="xICBSXPProxy.ProcessingError" id="2"> <Value>0</Value> </Parameter> <Parameter...

Syntax error in xml-writer

I have seen an example of an XML-writer in another quistion: <?php $writer = new XMLWriter(); $writer->openURI('php://output'); $writer->startDocument('1.0','UTF-8'); $writer->setIndent(4); $writer->startElement('items'); $writer->startElement("main"); ...

Jquery / XML No response when using xml generated from a php file

I want to load a xml file using Jquery . The xml is generated using a php script (Currently just using echo) My problem is that the file will just not produce and results . My Jquery is listed below $(document).ready(function() { $.ajax({ ...