Search Results

Search found 18472 results on 739 pages for 'vtd xml author'.

Page 80/739 | < Previous Page | 76 77 78 79 80 81 82 83 84 85 86 87  | Next Page >

  • How to find ordinal position of an element in XML using VBScript & XPATH

    - by chazzuka
    I have an XML like this <response> <doc> <arr name="URL"><str>string</str></arr> <arr name="ID"><int>1</int></arr> </doc> <doc> <arr name="URL"><str>string</str></arr> <arr name="ID"><int>2</int></arr> </doc> <doc> <arr name="URL"><str>string</str></arr> <arr name="ID"><int>3</int></arr> </doc> </response> How to get the ordinal position of doc element which has element arr(1)/int text = 2 I am Using Classic ASP thanks

    Read the article

  • align="right" doesn't work in xml

    - by Syom
    i've never used xml before, and now i must chenge the align of text. i try to do it like in html, but it doesn't happen. maybe i do something wrong? here is he script <gallery> <title><![CDATA[<FONT SIZE="20" COLOR="#C3A25D"></FONT>]]></title> <text><![CDATA[<FONT SIZE="20" COLOR="#C3A25D">text, which i want to to be in right position</FONT>]]></text> <thmb></thmb> <img wdt="421">images/avetiskhakhamyan.jpg</img> </gallery> i try to write align="right" in <font> tag, but it deosn't work. could you tell me what is the problem? thanks

    Read the article

  • Mixing JPA annotations and XML configuration

    - by HDave
    I have a fairly large (new) project in which we have annotated many domain classes with JPA mappings. Now it is time to implement many named queries -- some entities may have as many as 15-20 named queries. I am thinking that writing these named queries in annotations will clutter the source files and therefore am considering putting these in XML mapping files. Is this possible? Mort importantly, is this reasonable? Are there better approaches? How is this done?

    Read the article

  • Insert XML node before specific node using c#

    - by sam
    This is my XML file <employee> <name ref="a1" type="xxx"></name> <name ref="a2" type="yyy"></name> <name ref="a3" type="zzz"></name> </employee> Using C#, I need to insert this node <name ref="b2" type="aaa"></name> between the "a2" and "a3" nodes. Any pointer how to sort this out?

    Read the article

  • Selecting peculiar XML tags with phpQuery

    - by Aristotle
    phpQuery is a really nice tool which has helped me tremendously in the past parse well-formed XHTML and XML documents, but I have recently run into a problem trying to select elements that have colons in their tagname, such as the following: <isc:thumb><![CDATA[http://example.com/foo_thumb.jpg]]></isc:thumb> I've tried to use the pq() function to select all of these elements: foreach ( pq("isc:thumb") as $thumbnail ) { print pq( $thumbnail )->text(); } Unfortunately this is doing nothing. If I try another element, like a tagname of id, the results pop up as expected.

    Read the article

  • How to parse XML in VBA

    - by dev
    Hi, I work in VBA, and want to parse a string eg <PointN xsi:type='typens:PointN' xmlns:xsi='<http://www.w3.org/2001/XMLSchema-instance>' xmlns:xs='<http://www.w3.org/2001/XMLSchema>'><X>24.365</X><Y>78.63</Y></PointN> and get the X & Y values into two separate integer variables. I'm a newbie when it comes to XML, since I'm stuck in VB6 and VBA, because of the field I work in. How do I do this?

    Read the article

  • Decimal point removed from decimals in a Serialized XML

    - by MiguelM
    I'm using XmlSerializer with classes created from a xsd using xsd.exe. It has worked fine for months. Now I'm receiving reports that in some cases the created xml file has all decimals serialized without a decimal point, e.g. 123.45 is serialized as 12345. I haven't been able to reproduce the problem, but I'm suspecting it may be related to localization. This is my first C# project, so I may be overlooking something basic. Could localization cause this problem? How can I make the serialization process locale independent? Any idea of something else that could cause this problem?

    Read the article

  • Cannot access data in a xml string

    - by Jess McKenzie
    I am trying to create an array that I can include the perent category Name and the child category Name. I can so far access the below object fine using $xml->Subcategories; but if I try my code below I get an empty array why? PHP: foreach ($catDetailsXml->Category as $value) { $categoryDetails[] = array('CategoryNumber' => $value->Number); } Structure: object(SimpleXMLElement)#13 (1) { ["Category"]=> array(5) { [0]=> object(SimpleXMLElement)#14 (4) { ["Name"]=> string(19) "Commercial Property" ["Number"]=> string(10) "0350-0100-" ["Subcategories"]=> object(SimpleXMLElement)#35 (1) { ["Category"]=> array(3) { [0]=> object(SimpleXMLElement)#36 (4) { ["Name"]=> string(9) "Car parks" ["Number"]=> string(15) "0350-0100-8946-" ["Subcategories"]=> object(SimpleXMLElement)#39 (0) { } }

    Read the article

  • Send xml from ActionScript to PHP

    - by Vish
    Hi, I have values inside an XMLList in Actionscript. Need to send these values to the DB and update it. My actionscript code is as follows: http://www.freeimagehosting.net/uploads/dbbc612193.gif How can I send the XMLList data to PHP? Should I add a toString() to it? Also what should be the contentType in Flex. How can I catch this inside PHP, pl let me know, trying to use, this way, if($user - isAllowedAccess()) { header("Content-type:text/xml"); $postedData = $_POST["pdata"]; // $xmldoc = simplexml_load_string($POST['pdata']); // echo($xmldoc); } No luck. Pl let me know.

    Read the article

  • checking boolean property in XML(Spring)

    - by Abhishek Bhandari
    I am using Spring Framework . While writing coustum SQL queries , i am unable check a parameter of boolean value. For example this is not working .. do some SQl cods The above checking is not working , it is evaluating as equal in both the cases when booleanVariable is true and false . i tried to replace compareValue ="tree" and "false". As that is a monkey work i do sometimes . is it possible to check the boolean property in XML like above .

    Read the article

  • Return an object after parsing xml with SAX

    - by sentimental_turtle
    I have some large XML files to parse and have created an object class to contain my relevant data. Unfortunately, I am unsure how to return the object for later processing. Right now I pickle my data and moments later depickle the object for access. This seems wasteful, and there surely must be a way of grabbing my data without hitting the disk. def endElement(self, name): if name == "info": # done collecting this iteration self.data.setX(self.x) self.data.setY(self.y) elif name == "lastTagOfInterest": # done with file # want to return my object from here filehandler = open(self.outputname + ".pi", "w") pickle.dump(self.data, filehandler) filehandler.close() I have tried putting a return statement in my endElement tag, but that does not seem to get passed up the chain to where I call the SAX parser. Thanks for any tips.

    Read the article

  • Return XML data from a web service

    - by Nick LaMarca
    What is the best way to create a web service that returns a set of x,y coordinates? I am not sure on the object that is the best return type. When consuming the service I want to have it come back as xml preferibly something like this for example: <TheData> <Point> <x>0</x> <y>2</y> </Point> <Point> <x>5</x> <y>3</y> </Point> </TheData> If someone has a better structure to return please help I am new at all this.

    Read the article

  • Creating hashmap/map from XML resources

    - by KimAMartinsen
    Hi! I'm making an application where a web service fetches (amongst other) a bunch of codes from a webservice (I.e BEL, FRA, SWE). During runtime I want to translate these codes to their apporiate names to display to users (I.e Belgium, France, Sweden). There can be a lot of these codes, so i'm wondering if there is any approriate way to store the (code, name) entry as a some sort of map in the XML resources in Android, so I can quickly fetch the name by the given code? It's all about speed here, since the map can have a few hundred entries.

    Read the article

  • XPath selection from path in XML content

    - by Wayne Robinson
    I have the following XML: <root> <name>The name</name> <long> <path> <value>Some Value</value> </path> </long> <field>/root/name</field> <field>/root/long/path/value</field> </root> and I want to select these paths in the field tags however, when I try the following: <xsl:value-of select="/root/field[1]" /> all I get is the text value of the field. Is there a way of selecting the correct node from those values?

    Read the article

  • Transforming large Xml files

    - by Chad
    I was using this extension method to transform very large xml files with an xslt. Unfortunately, I get an OutOfMemoryException on the source.ToString() line. I realize there must be a better way, I'm just not sure what that would be? public static XElement Transform(this XElement source, string xslPath, XsltArgumentList arguments) { var doc = new XmlDocument(); doc.LoadXml(source.ToString()); var xsl = new XslCompiledTransform(); xsl.Load(xslPath); using (var swDocument = new StringWriter(System.Globalization.CultureInfo.InvariantCulture)) { using (var xtw = new XmlTextWriter(swDocument)) { xsl.Transform((doc.CreateNavigator()), arguments, xtw); xtw.Flush(); return XElement.Parse(swDocument.ToString()); } } } Thoughts? Solutions? Etc.

    Read the article

  • XML comments and "--"

    - by Vi.
    <!-- here is some comment -- ^ | what can be here apart from '>'? XML seems not to like '--' inside comments. I read somewhere that '--' switchs some modes inside <! ... > thing, but <!-- -- -- --> (even number of --s) seem to be invalid too. If it is some historic feature, what is "pro" part of it? ("contra" part is inability to have -- in comments). What is the reason of complicating comment processing by not making just '--' end of comment and allowing '--' inside?

    Read the article

  • Grep in XML file

    - by nishant
    I have to find some patters from a XML file, but i am unable to do it. <field> <uniqueid>account </uniqueod> <tableid>afs</tableid> </field> <field> <uniqueid>address</uniqueod> <tableid>afs</tableid> </field> what i have to do is to search the entries between these two fields and redirect them to a file.txt.and output should be such that uniqueid tableid uniqueid tableid i.e. for each uniqueid tableid should be printed along with it. The entries can be different or same. Guys help me out...

    Read the article

  • Getting information from an XML object in PHP

    - by errata
    Hi! I am using some XML parser to get some information from API, blah blah... :) In one place in my script, I need to convert string to int but I'm not sure how... Here is my object: object(parserXMLElement)#45 (4) { ["name:private"]=> string(7) "balance" ["data:private"]=> object(SimpleXMLElement)#46 (1) { [0]=> string(12) "11426.46" } ["children:private"]=> NULL ["rows:private"]=> NULL } I need to have this string "11426.46" stored in some var as integer. When I echo $parsed->result->balance I get that string, but if I want to cast it as int, the result is: 1. Please help! Thanks a lot!

    Read the article

  • Storing Data as XML BLOB

    - by NBrowne
    Hi, At the moment the team i am working with is looking into the possibility of storing data which is entered by users from a series of input wizard screens as an XML blob in the database. the main reason for this being that i would like to write the input wizard as a component which can be brought into a number of systems without having to bring with it a large table structure. To try to clarify if the wizard has 100 input fields (for example) then if i go with the normal relational db structure then their will be a 1 to 1 relationship so will have 100 columns in database. So to get this working in another system will have to bring the tables,strore procedures etc into the new system. I have a number of reservations about this but i would like peoples opinions?? thanks

    Read the article

  • marshal Map<String, String> to .xml

    - by richardl
    If I have Map setup like: map.put("foo", "123"); map.put("bar", "456"); map.put("baz", "789"); then I want to do something like: for (String key : map.keySet().toArray(new String[0])) { // marshall out to .xml a tag with the name key and the // value map.get(key) } So what it will marshal out is something like: <map> <foo>123</foo> <bar>456</bar> <baz>789</baz> </map> Can I do this with some fancy JAXB annotations or is there something else that lends it self to dynamic element names? TIA

    Read the article

  • Check if XML node is empty

    - by Vinit
    I have a simple XML structure like <main> <node1><!-- comments --><!-- comments --></node1> </main> and this can have any number of sub-nodes or values like: <main> <node1><!-- comments --><!-- comments --><p>texttext text</p> more text <br/></node1> </main> I want to check if the node is empty or not: I'm doing something like: <xsl:if test="string-length(main/node1//text())&gt;0"> But it does not work as if there are multiple tags, then string-length function will break coz of multiple arguments. Any help to solve this issue is really appreciated.

    Read the article

  • Best way to parse XMPP-like XML streams?

    - by codethief
    I am working on a server application which receives data over a TCP socket in an XMPP-like XML format, i.e. every child of the <root> element essentially represents one separate request (stanza). The connection is closed as soon as </root> is received. I do know that I must use a stream parser like SAX, somehow. Though, for convenience, I'd prefer to have a tree-like interface to access each stanza's child elements. (The data sent with every request is not large so I think it makes sense to read each stanza as a whole.) What's the best way to realize that in Python (preferably v3)? This is the code I'd like to build it in. Feel free to point me in a totally different direction to solve this issue. import socketserver import settings class MyServer(socketserver.ThreadingMixIn, socketserver.TCPServer): pass class MyRequestHandler(socketserver.StreamRequestHandler): def handle(self): pass if __name__ == '__main__': server = MyServer((settings.host, settings.port), MyRequestHandler) server.serve_forever()

    Read the article

  • Read a String as XML in .NET 2.0

    - by Chin
    I have a string that is coming from DB. I would like to read this as XML. String looks like below <settings> <setting name="OfferIDs" value="47,48,49,50,51,52,53,76,77,78,79" /> <setting name="someothersetting" value="" /> <setting name="anothersetting" value="" /> </settings> I would like get the value of OfferIDs as a string using VB.NET. Many Thanks in advance.

    Read the article

  • Loading XML with possible infinite tags

    - by Firstmate
    (I'm doing this in AS3, but I'm sure the answer could be given in psuedocode) Basically, I have a XML file similar to: <Main> <Event> <Name>Blah</Name> <Event> Name>Blah2</Name> <Event> <Name>Blah3</Name> ... </Event> </Event> </Event> </Main> Yeah, to some extent it's poor design. But the idea I'm going for is that any Event has the potential to compromise of other Events and this idea kinda loops. Any ideas on how to do this?

    Read the article

< Previous Page | 76 77 78 79 80 81 82 83 84 85 86 87  | Next Page >