xml

Parsing Custom Tags with PHP

I am trying to make simple custom tags to allow custom templates on my app. But I can't figure out how to parse and replace the tags. (example) <div class="blog"> <module display="posts" limit="10" show="excerpt" /> </div> <div class="sidebar"> <module display="users" limit="5" /> <module display="comment" limit="10" /> </div> for e...

Loading XML into a flash object.

Hello, I am trying to load data from an XML file into a flash object. When making the flash object in actionscript it looks like this: var presentationObj:Object = { casestudies: { audi: { titleStr: 'Audi', placement: 'study', slides:{ 1:{ src:'img/page1.jpg', group:'img' }, 2:{ src:'img/page2.jpg', group:'img' } } } } ...

Consume REST service with JME (or J2ME)

Hello, I need some help getting started with this. I need to know how to call the REST service and parse the xml. My php script only sends back some xmlcode, nothing else.(no wsdl or uddi) The platform for the Nokia 5800 is S60 third edition.(that one will apply) The Nokia sdk go's by the same name. I installed Netbeans for this pro...

IE: Clone XML Data Island into IFrame

First off, YES, this is for IE and IE only. NO, I cannot deviate from that. I am working on a corporate intranet application and I have no say whatsoever about the client browser; thus, it is IE (and IE 6, at that). Now, the gist of what I'm trying to do is this: the application houses several XML data islands, and at times I need to pr...

How to convert SQL Server XML type value (xsi:nil) of DateTime to null

Is there a way to query SQL Server XML type so that for an element with xsi:nil="true", return null instead of default datetime value, which is 1900-01-01 00:00:00.000? here is a code snippet declare @data xml set @data = '<DOD xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:nil="true" />' select Value1 = @data.value('/...

PHP DOM Dumb Question- Add Nested Children

Hi All, I am moving some code from SimpleXML to php's DOM and don't quite get the objects yet. In SimpleXML, for example, I can create nested elements very easily like so: $Settings = new SimpleXMLElement("<root></root>"); $Settings->addChild('el1'); $Settings->el1->addChild('el2'); $Settings->el1->el2->addChild('el3'); $Settings->el1...

Java and xpath - xHtml parsing problem

I'm trying to parse a well formed xhtml document. I'm having problems during the nodes iteration. My xHtml has a structure like <?xml version="1.0" encoding="UTF-8"?> <html> <head>...</head> <body> ... <form> ... <div class="AB"> (1 or 2 times) ... <div class="CD"> ... <tab...

How can I visualise Reddit's XML-schema in XVCG or Dotty?

You can find the schema. So how can I visualise it to see dependencies, packages and such things? ...

DTD Entities vs XML-Schema Elements

Hi, using an in Document DTD I did the following: file.xsl: <!DOCTYPE xsl:stylesheet[ <!ENTITY red "rgb(255,0,0)"> ]> <xsl:stylesheet> [...] <xsl:attribute name="color">&red;</xsl:attribute> [...] </xsl:stylesheet> I wanted to change everything to XML-Schema. So I tried: file.xsd: <xsd:schema xmlns:xsd="http://www.w3.o...

Plan for building xml file containing custom designed blog posts/comments for import into WordPress via Clojure

I'm trying to migrate from a custom designed blog software system to a WordPress.com site. I can access my MySQL database of posts and comments without too much difficulty, thanks in part to this post: http://stackoverflow.com/questions/613929/how-do-i-connect-to-a-mysql-database-from-clojure. I think my next step is to generate the ps...

how to wrap/store the key of TripleDESCryptoServiceProvider

I'm using DES encryption, and I want to store the key of TripleDESCryptoServiceProvider. But the key consists of (Key + IV), I was trying to save them in an XML file using XmlTextWriter Convert.ToBase64String(...) but there was an exception due to IV contains invalid characters "=" in XML. Is there a better way to store symmetri...

hyperlink cell elements passed in a Flex datagrid

I'm trying to render a Flex datagrid using an external XML datasource. Is there a way I can specify in the XML that a cell element should appear as a hyperlink? ...

ASP.net check box label name from xml

I have a check box in an asp.net webpage How to fill the labek name of the check box from an xml file ? I did the same for dropdown but i want similar to checkbox xmlData.ReadXml(Server.MapPath("./App_Data/view1_" + txt_dropDownToLoad + ".xml")) DropDownName.DataSource = xmlData DropDownName.DataValueField = "ddl_cod" DropDownName.D...

PHP5: Find Root Node in DOMDocument

I have a PHP5 DOMDocument and I try to find the root node (not the root element). Example: <test> <element> <bla1>x</bla1> <bla2>x</bla2> </element> <element> <bla1>y</bla1> <bla2>y</bla2> </element> <element> <bla1>z</bla1> <bla2>z</bla2> </element> </test> I wa...

C# Serializaton Question

In the first scenario, everything is pretty easy, I have the following XML, that I can deserialize to a strong type. <providers> <dprovider> <dimensions> <width></width> </dimensions> </dbrovider> In the 2nd scenario, and this is where I need help... I have something a little more dynamic <providers> <d...

Checking node contents against a given set of values

Given an XML document such as this: <root> <foo> <bar>a</bar> <bar>b</bar> <bar>c</bar> </foo> ... </root> How can I retrieve all foo-nodes that have bar-subnodes with certain values? So for instance, if I need all foo-elements that have bar-subelements with values a and c, I am currently using thi...

How can I select XElements where Attribute ... (LINQ2XML)

How can I select the Value where id == id && key == key with Linq xml: <Localization> <Module id="Customers"> <CultureCode>de-DE</CultureCode> <Key>General</Key> <Value>Allgemeine Kunden</Value> </Module> <Module id="Contract"> <CultureCode>de-DE</CultureCode> <Key>General</Key> <Value>Allgemeine ...

output xml fragment without headers

I have a feeling I'm being thick, but here's my problem: I'm creating dynamic XML trees using PHP. These trees describe employee hierarchies, file directories, etc. They comprise small sections of content on a webpage. The rest of the webpage is glued together from various other sources that may be SQL based, or static text or some s...

How do I load unsanitized XML?

We have various XML files produced by an application in current distribution. Some of these files have turned out to contain invalid characters, rendering them invalid XML that won't load in most instances unless all validation is turned off, and then, only in XmlDocument instances, not XDocument. As this app is already out there, we ha...

Flash AS3 load file xml

Hello, I'm just trying to load an xml file witch can be anywere in the hdd, this is what I have done to browse it, but later when I'm trying to load the file it would only look in the same path of the swf file here is the code package { import flash.display.Sprite; import flash.events.; import flash.net.; public class carg...