xml

Silverlight ASP.NET MVC RESTful approach

I use Silverlight 3 with ASP.NET MVC. For database operations I query SQL Server database using FOR XML, and send the data as XML over wire to Silverlight client where it is deserialized to business object. Is this approach good? I do not find much resource on Internet about using Silverlight, ASP.NET and XML together. ...

XLinq with encrypted files?

How do I create/read/write XLinq and/or VB XML Literals from and to encrypted xml files? ...

Where to find a good tutorial and examples of CSOAP?

I started to work with CSOAP (see http://csoap.sourceforge.net) and when searched on google, I didn't find a good tutorial of CSOAP. Could you plz direct me to anything relevant from where to start? Thanks! ...

How to Decode base 64 data

I have an XML doucment in which there is an tag for image like this if there is an image then the tag would be as follows <thumbnail> <type>IMAGE JPG</type> <data> base64 data </data> </thumbnail> And if there is no image then <thumbnail/> I want to get the base64 encoded image using DOM parser and how to handle tags which don't...

Add a dtd using nokogiri builder

I am using nokogiri to generate svg pictures. I would like to add the correct xml preamble and svg DTD declaration to get something like: <?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"&gt; <svg> ... With builder I could use instruct! and declare!...

How to create an xml database?

How can I create an XML database? Please tell me any DBMS help me to create database stored XML document. I will use an existing server for querying but first create the XML database itself. I realy confused between xml db and db that support xml plz explain the difference between them and how to create both? ...

XML text in form textarea...how to accept that as XML into PHP?

Is there an easy way to do this in PHP? How do you take plain text, formatted as XML, from a form textarea and have PHP take it in as XML? I can find out how to walk the tree after it's an XML object. Just tried richsage's technique on this sample xml: <?xml version="1.0"?> <videocollection> <title id="1">Tootsie</title> <...

Passing Xml from jquery to wcf method

hi, I am sending xml from jquery ajax method to WCF method replacing all special characters. my jquery method structure is : function UpdateUserProfile(UserId ) { var reqParams = { LinkedinUrl:$("#hdnProf").val(), LinkedinFeed:$("#hdnfeed").val() }; } var reqParams_Serialized = Sys.Serialization.JavaScript...

xml to mysql database

I have a question. Does anyone have a working php script which can parse a XML file to a sql database? I have searched for some scripts and didn't find anything what looks like I can edit it to my needs. Any help would be great! ...

Is XPath a better a way to read configuration file than using SAX / DOM parsers?

Is XPath a better way to read configuration file than DOM and SAX? If yes, Why does not log4j uses XPathExpression to read configuration file? If No, What method should I choose so that I do not have to modify the code if my configuration file changes? Update: @kdgregory Normally you are aware of the parameter you are seeking in a ...

Can't access Element after DataContractSerializer

I have a simple object I'm trying to serialize using DataContractSerializer. In my unit test, I'm trying to verify the xml contains the right value for the product/sku node. My product class: [DataContract(Namespace = "http://foo.com/catalogue/") partial class Product { [DataMember(Name = "sku")] public virtual string ProductSKU...

Flatten XML using multiple XPath expressions

I'm looking for a generic algorithm which can flatten a XML file into a table, given multiple XPath expressions and all things i've tried failed due to the nature of available XPath engines implementations. Given a XML: <A Name="NameA"> <B Name="NameB1"> <C Name="NameC1"/> <C Name="NameC2"/> <C Name="NameC3"/> </B> <B Name="NameB2">...

XML Structure creations issue

I data in the below format (List of HashMap's) {TeamName=India, Name=Sachin, Score=170} {TeamName=India, Name=Sehwag, Score=120} {TeamName=Sri-Lanka, Name=Sangakara, Score=20} {TeamName=Sri-Lanka, Name=Murali, Score=20} {TeamName=Sri-Lanka, Name=Jayasurya, Score=70} Below is the desired output <node id="1" label="India" > <no...

Proper XML Syntax

Is this a correct way to store an address in an XML file? If it is, how would I echo it in three lines like an address should be written using PHP. If not what is the correct way? (The file is not complete. I am only interested in the address.) <store name="Pizza R Us" Store_address="16 Main St Anytown, US 00000"> <items> <pizzas> ...

Empty xml element for future use

If I want to make adding something to an XML file very simple can I do this: <small>$1.99</small> <medium></medium> <large>$3.99</large> Can I leave the medium element blank and tell the php parser to ignore it? I'm thinking that when I parse it I am going to want all the sizes returned but not a size with no price. ...

Check Empty XML data validation before displaying

I want to check xml before displaying it .I am using XPath not xsl for it. For e.g. <title></title> <url></url> <submit></submit> i wanna check that if xml data is not there for it . Then don't display it. because I m putting these values in <a href=<%#container.dataitem,url%>>new link</a>. So i want that if url is empty then don't d...

XML cross-browser support

I need help getting the file to run in Firefox: I have tried adapting scripts so that my file runs in both IE and Firefox but so far it still only works in IE. (The file can be tested at http://www.eyle.org/crosstest.html - simply type the word Mike in the text box using IE (doesn't work in Firefox).The HTML document is: <!DOCTYPE html ...

Why do I get "Invalid predicate" error from getElementsByTagName?

Hi, I get the following XML: <config> <version general="1.2.3"> <subtype type="a" version="1.2" /> <subtype type="b" version="3.6" /> ... </version> ... </config> I have some code in Perl to get the config node from a database. After I get it, if I try the follwoing: my $elem = $cfg->getElementsByTagName("version"...

How to get Text-only results from Twitter Search Feeds?

I'm writing a simple Twitter example that reads the Twitter Search RSS feed via: http://search.twitter.com/search.rss This works well except that the Description in this contains HTML such as Bold Tags and Link Tags, I have looked at the Atom feed via: http://search.twitter.com/search.atom It also has HTML in the description, is th...

problem in sort by date---> xml

Hi, I have a xml and I want to sort it by date.my code till now is this XmlDocument doc = new XmlDocument(); doc.Load("/ABC.xml"); XPathNavigator nav = doc.CreateNavigator(); //doing some filtering and creating xpath expression based on that XPathExpression expression = nav.Compile(xpath); XPathExpression sorte...