From jeffl at hypershell.com Wed Mar 2 16:30:37 2005 From: jeffl at hypershell.com (Jean-Francois Lambert) Date: Wed Mar 2 16:28:36 2005 Subject: [Expat-discuss] Expat for Windows CE? Message-ID: I tried a while ago to compile Expat for WinCE and failed miserably. >From what I can remember, it was about Windows CE not having access to the STL library that Expat depends on? I was wondering if any attempts were made to succesfully compile Expat on Windows CE. I would greatly appreciate any help and step-by-step approach using Embedded Visual C++ 4.0. Basically if I could just have a .DLL and .Lib I'd be happy. If I'm way out of it, let me know. Jeff Lambert From karl at waclawek.net Wed Mar 2 16:54:50 2005 From: karl at waclawek.net (Karl Waclawek) Date: Wed Mar 2 16:54:59 2005 Subject: [Expat-discuss] Expat for Windows CE? In-Reply-To: References: Message-ID: <4225E1CA.40909@waclawek.net> Jean-Francois Lambert wrote: > I tried a while ago to compile Expat for WinCE and failed miserably. >>From what I can remember, it was about Windows CE not having access to > the STL library that Expat depends on? Expat is pure C, no STL required. > I was wondering if any attempts were made to succesfully compile Expat > on Windows CE. I would greatly appreciate any help and step-by-step > approach using Embedded Visual C++ 4.0. Basically if I could just have a > .DLL and .Lib I'd be happy. Expat compiles fine with Visual C++ 6.0. Unfortunately I don't know how that is different from compiling with Embedded Visual C++. Karl From mike at mikeware.cz Wed Mar 2 16:50:53 2005 From: mike at mikeware.cz (Mike) Date: Wed Mar 2 17:04:38 2005 Subject: [Expat-discuss] Expat for Windows CE? In-Reply-To: Message-ID: <20050302160148.320AC30015@ns.arachne.cz> I compiled and used expat on WinCE some time ago successfully, can't remember any critical caveats. Try to google for WinCE port, i'm sure you find something. Anyway, AFAIK STL is not implemented in Windows CE at all and Expat doesn't rely on STL by any way. If you're porting your app from Win32 to WinCE, it's usually not as simple as copy sources and recompile ;-) if you use anything more than pure c/c++. Mike > -----Original Message----- > From: expat-discuss-bounces@libexpat.org > [mailto:expat-discuss-bounces@libexpat.org] On Behalf Of > Jean-Francois Lambert > Sent: Wednesday, March 02, 2005 4:31 PM > To: expat-discuss@libexpat.org > Subject: [Expat-discuss] Expat for Windows CE? > > I tried a while ago to compile Expat for WinCE and failed miserably. > >From what I can remember, it was about Windows CE not having > access to > the STL library that Expat depends on? > > I was wondering if any attempts were made to succesfully compile Expat > on Windows CE. I would greatly appreciate any help and step-by-step > approach using Embedded Visual C++ 4.0. Basically if I could > just have a > .DLL and .Lib I'd be happy. > > If I'm way out of it, let me know. > > Jeff Lambert > _______________________________________________ > Expat-discuss mailing list > Expat-discuss@libexpat.org > http://mail.libexpat.org/mailman/listinfo/expat-discuss > From mikael.ryding at ericsson.com Fri Mar 4 17:33:23 2005 From: mikael.ryding at ericsson.com (Mikael Ryding (LI/EAB)) Date: Fri Mar 4 19:12:47 2005 Subject: [Expat-discuss] Verify xml-file with dtd? Message-ID: <63E39ADA42BF8B49BEAE3666683A2484383FD1@esealmw107.eemea.ericsson.se> Hi! I'm writing a program that uses EXPAT to parse an xml-file and to verify its structure with a dtd-file, but it ONLY verifies the syntax for the xml-ile and dtd-file separately, I don't manage to get the parser to compare the files and verify that the xml-file "implements" the dtd so to speak. I can use any valid DTD (that has nothing to do with my xml-file) and the parser finds it ok. Does someone have an idea what I do wrong? Below is part of the code that includes the DTD-parts (everything else removed): --------------------------- int dtdHandler (XML_Parser parser, const XML_Char *context, const XML_Char *base, const XML_Char *systemId, const XML_Char *publicId) { XML_Parser dtdParser = XML_ExternalEntityParserCreate(parser, context, 0); status = XML_Parse(dtdParser, buf, len, 1); if (!status) { printf("dtdparsing: %s at line %d, column: %d, errorCode: %d\n", XML_ErrorString(XML_GetErrorCode(dtdParser)), XML_GetCurrentLineNumber(dtdParser), XML_GetCurrentColumnNumber(dtdParser)); return XML_ERROR_EXTERNAL_ENTITY_HANDLING; } return status; } ---------------------------- int main () { /* Set user data */ XML_SetUserData(parser, fd_p); /* DTD parsing */ XML_SetExternalEntityRefHandler(parser, dtdHandler); XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS); /* Set element and character data handler */ XML_SetElementHandler(parser, startElement, endElement); do { if (!XML_Parse(parser, buf, len, len==0)) { printf("xmlparsing: %s at line %d, column: %d\n", XML_ErrorString(XML_GetErrorCode(parser)), XML_GetCurrentLineNumber(parser), XML_GetCurrentColumnNumber(parser)); } } Regards, Mikael From reid at x10sys.com Fri Mar 4 19:30:40 2005 From: reid at x10sys.com (Reid Spencer) Date: Fri Mar 4 19:30:45 2005 Subject: [Expat-discuss] Verify xml-file with dtd? In-Reply-To: <63E39ADA42BF8B49BEAE3666683A2484383FD1@esealmw107.eemea.ericsson.se> References: <63E39ADA42BF8B49BEAE3666683A2484383FD1@esealmw107.eemea.ericsson.se> Message-ID: <1109961040.4013.101.camel@bashful.x10sys.com> Expat doesn't support document validation. It only does a well-formedness check on the input (making sure tags are properly constructed and balanced). If you need validation, you can either roll your own, use XML Schema or Relax NG, or use an xml parser that supports validation (libxml2, Xerces). Reid. On Fri, 2005-03-04 at 08:33, Mikael Ryding (LI/EAB) wrote: > Hi! > > I'm writing a program that uses EXPAT to parse an xml-file and to verify its structure with a dtd-file, but it ONLY verifies the syntax for the xml-ile and dtd-file separately, I don't manage to get the parser to compare the files and verify that the xml-file "implements" the dtd so to speak. I can use any valid DTD (that has nothing to do with my xml-file) and the parser finds it ok. > > > Does someone have an idea what I do wrong? Below is part of the code that includes the DTD-parts (everything else removed): > --------------------------- > > int dtdHandler (XML_Parser parser, const XML_Char *context, const XML_Char *base, > const XML_Char *systemId, const XML_Char *publicId) > { > XML_Parser dtdParser = XML_ExternalEntityParserCreate(parser, context, 0); > status = XML_Parse(dtdParser, buf, len, 1); > if (!status) { > printf("dtdparsing: %s at line %d, column: %d, errorCode: %d\n", > XML_ErrorString(XML_GetErrorCode(dtdParser)), > XML_GetCurrentLineNumber(dtdParser), > XML_GetCurrentColumnNumber(dtdParser)); > return XML_ERROR_EXTERNAL_ENTITY_HANDLING; > } > return status; > } > ---------------------------- > int main () > { > /* Set user data */ > XML_SetUserData(parser, fd_p); > > /* DTD parsing */ > XML_SetExternalEntityRefHandler(parser, dtdHandler); > XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS); > > /* Set element and character data handler */ > XML_SetElementHandler(parser, startElement, endElement); > > do { > if (!XML_Parse(parser, buf, len, len==0)) { > printf("xmlparsing: %s at line %d, column: %d\n", > XML_ErrorString(XML_GetErrorCode(parser)), > XML_GetCurrentLineNumber(parser), > XML_GetCurrentColumnNumber(parser)); > > } > } > > > Regards, Mikael > _______________________________________________ > Expat-discuss mailing list > Expat-discuss@libexpat.org > http://mail.libexpat.org/mailman/listinfo/expat-discuss -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part Url : http://mail.libexpat.org/pipermail/expat-discuss/attachments/20050304/7873b078/attachment.pgp From j.chen at ustc.edu Fri Mar 11 05:50:37 2005 From: j.chen at ustc.edu (=?utf-8?B??=) Date: Fri Mar 11 21:01:27 2005 Subject: [Expat-discuss] How to make expat support east asia languages Message-ID: <20050311044938.5D78E1E4005@bag.python.org> Hi, Does any one know how to make expat support east asia languages? such as Chinese, Korean and so on. Currently, expat's output is some un-recognizable characters when parsing an XML file which contains some east asia languages' characters. Does any one know how to fix this problem? Many thanks! Legol 2005-03-11 j.chen@ustc.edu From karl at waclawek.net Sat Mar 12 00:12:19 2005 From: karl at waclawek.net (Karl Waclawek) Date: Sat Mar 12 00:12:08 2005 Subject: [Expat-discuss] How to make expat support east asia languages In-Reply-To: <20050311044938.5D78E1E4005@bag.python.org> References: <20050311044938.5D78E1E4005@bag.python.org> Message-ID: <423225D3.6000903@waclawek.net> j.chen@ustc.edu wrote: > Hi, > Does any one know how to make expat support east asia languages? such as Chinese, Korean and so on. > Currently, expat's output is some un-recognizable characters when parsing an XML file which contains some east asia languages' characters. Does any one know how to fix this problem? Expat always uses the UTF-8 or UTF-16 encoding of Unicode when passing data to the application, regardless of which encoding the source document is in. Karl From lee_guoquan at hotmail.com Sun Mar 13 03:49:04 2005 From: lee_guoquan at hotmail.com (Guoquan Lee) Date: Sun Mar 13 03:49:08 2005 Subject: [Expat-discuss] need to free after calling XML_GetBuffer? Message-ID: Hi I am having some error using expat in c++. I get XML_STATUS_ERROR after calling XML_GetBuffer. I am calling XML_GetBuffer within a while loop like this: while(carry_on) { void *buff = XML_GetBuffer(p,10240); // p is a xml parser if(buff == NULL) return; bytes_read = read(fd, buff, 10240); //fd is a file descriptor pointing to a xml document of interest if(bytes_read < 0) return; status = XML_ParseBuffer(p, buff, bytes_read, bytes_read==0); //status is of type XML_Status if(status ==XML_STATUS_ERROR) { std::cout<<"status error"<<"\n"; return; } } I looked into the contents of buff when the program reported XML_STATUS_ERROR and realized that some of the contents in buff were from the previous iteration of XML_GetBuffer. Why is that? What is the cause of XML_STATUS_ERROR and how to rectify it? Thank you. _________________________________________________________________ Get an advanced look at the new version of MSN Messenger. http://messenger.msn.com.sg/Beta/Default.aspx From karl at waclawek.net Tue Mar 15 00:47:55 2005 From: karl at waclawek.net (Karl Waclawek) Date: Tue Mar 15 00:47:43 2005 Subject: [Expat-discuss] How to make expat support east asia languages In-Reply-To: <20050314045930.CE0833FC0D@mail.zoneedit.com> References: <20050314045930.CE0833FC0D@mail.zoneedit.com> Message-ID: <423622AB.9090607@waclawek.net> ?? wrote: >>j.chen@ustc.edu wrote: >> >>>Hi, >>> Does any one know how to make expat support east asia languages? such as Chinese, Korean and so on. >>> Currently, expat's output is some un-recognizable characters when parsing an XML file which contains some east asia languages' characters. Does any one know how to fix this problem? >> >>Expat always uses the UTF-8 or UTF-16 encoding of Unicode >>when passing data to the application, regardless of which encoding >>the source document is in. >> >>Karl >> >> > > > Well..., when I use expat to parse a very very simple xml, which including some Chinese characters in it, like "??", a "not well formed document" error occured. However, when I change the xml to "test" , everything is ok. > > So, could you please tell me why ? > > And what's more, in many Chinese XML tech. discussion forum, it is said clearly that expat do not support Chinese. So, maybe there is some problem with expat when parsing some multi-byte coding language. Do you know how to fix it? > We have to differentiate between input and output. For output, most XML parser support Unicode only. For input, Expat supports UTF-8, UTF-16, ISO-8859-1 and ASCII. If you implement the unknownEmcodingHandler() then Expat can support more encodings. If you check out patch # 888879, you will find that someone supplied such an implementation for the gb3212 encoding. However, the standard encoding is Unicode, which supports basically all characters of all languages, including Asian languages. If you have a choice, I recommend to abandon the older multi-byte encodings for Asian characters and switch to unicode. Karl From karl at waclawek.net Tue Mar 15 14:10:56 2005 From: karl at waclawek.net (Karl Waclawek) Date: Tue Mar 15 14:10:43 2005 Subject: [Expat-discuss] How to make expat support east asia languages In-Reply-To: <20050315031643.20925400FD@mail.zoneedit.com> References: <20050315031643.20925400FD@mail.zoneedit.com> Message-ID: <4236DEE0.5030402@waclawek.net> J.Chen wrote: > Yes, my input xml file is UTF-8 coding. expat still can't parse it... What error does Expat return? Maybe your file has errors? Or is it the case that Expat does not return an error, but you can't display the characters? In this case, the propblem is not with Expat, but with your GUI controls that cannot display these Unicode characters. Karl From AAbdoh at informobility.com Tue Mar 15 15:32:00 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Tue Mar 15 15:30:57 2005 Subject: [Expat-discuss] syExpat problem Message-ID: <20050315143050.DE61A1800456@mwinf4012.affiliated.me-wanadoo.net> Hi all, I am trying to write a simple example of parsing a simple text and searching for a specific element, then hold its data. But I don't know how to do it. I trying hard to do it but no use. Anyone know about it, please tell me because I need it urgently! Thanks in advance. From AAbdoh at informobility.com Wed Mar 16 08:56:09 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Wed Mar 16 08:55:49 2005 Subject: [Expat-discuss] syExpat Handler Message-ID: <20050316075545.336321C001CA@mwinf4011.affiliated.me-wanadoo.net> Hi everybody, I am using Series 60 platform, I want to parse an xml file using syExpat xml parser. The example file Elements.cpp handling the output with RText class, but I want to put the Read text of the desired element in a CEikLabel, Knowing that I am using Borland BuilderX Mobile Edition. Thanks in advance. From paul at toddsoftware.com Wed Mar 16 09:13:29 2005 From: paul at toddsoftware.com (Paul Todd) Date: Wed Mar 16 09:12:27 2005 Subject: [Expat-discuss] syExpat Handler In-Reply-To: <20050316075545.336321C001CA@mwinf4011.affiliated.me-wanadoo.net> References: <20050316075545.336321C001CA@mwinf4011.affiliated.me-wanadoo.net> Message-ID: <4237EAA9.2070205@toddsoftware.com> Pass a pointer to the CEiKLabel control into the parser and then use that to update the text in the labvel, or store a TBuf or HBufC* inside the class implementing the parser callback and then when the xml file has finished parsing or you have located your element, copy the text from the class implementing the parser callback and put it into the label text. Paul Ashraf Abdoh wrote: >Hi everybody, > >I am using Series 60 platform, I want to parse an xml file using syExpat xml >parser. > >The example file Elements.cpp handling the output with RText class, but I >want to put the > >Read text of the desired element in a CEikLabel, > >Knowing that I am using Borland BuilderX Mobile Edition. > > > >Thanks in advance. > >_______________________________________________ >Expat-discuss mailing list >Expat-discuss@libexpat.org >http://mail.libexpat.org/mailman/listinfo/expat-discuss > > > From AAbdoh at informobility.com Wed Mar 16 11:14:12 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Wed Mar 16 11:13:10 2005 Subject: FW: [Expat-discuss] syExpat Handler Message-ID: <20050316101303.312711C00352@mwinf4011.affiliated.me-wanadoo.net> -----Original Message----- From: Ashraf Abdoh [mailto:AAbdoh@informobility.com] Sent: Wednesday, March 16, 2005 12:01 PM To: 'Paul Todd' Subject: RE: [Expat-discuss] syExpat Handler Hi, Thank you for your response. Could you please explain it in detail please, Because in the XmlHelper.h I made a public data member iData of type HBufC*, storing data in it as done in the GoogleIt example. But when running the program it closes with a message "Program Close :OK" Without giving any reason for the error. Thanks in advance. -----Original Message----- From: Paul Todd [mailto:paul@toddsoftware.com] Sent: Wednesday, March 16, 2005 10:13 AM To: AAbdoh@informobility.com Cc: expat-discuss@libexpat.org Subject: Re: [Expat-discuss] syExpat Handler Pass a pointer to the CEiKLabel control into the parser and then use that to update the text in the labvel, or store a TBuf or HBufC* inside the class implementing the parser callback and then when the xml file has finished parsing or you have located your element, copy the text from the class implementing the parser callback and put it into the label text. Paul Ashraf Abdoh wrote: >Hi everybody, > >I am using Series 60 platform, I want to parse an xml file using syExpat xml >parser. > >The example file Elements.cpp handling the output with RText class, but I >want to put the > >Read text of the desired element in a CEikLabel, > >Knowing that I am using Borland BuilderX Mobile Edition. > > > >Thanks in advance. > >_______________________________________________ >Expat-discuss mailing list >Expat-discuss@libexpat.org >http://mail.libexpat.org/mailman/listinfo/expat-discuss > > > From AAbdoh at informobility.com Thu Mar 17 09:00:36 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Thu Mar 17 08:59:31 2005 Subject: [Expat-discuss] emulator allocation error Message-ID: <20050317075927.E0CE31C001D3@mwinf4011.affiliated.me-wanadoo.net> Hi, I am working with syExpat as an xml parser; it parses a text and holds it into a text box, But when I press the EXIT button I have the error message: Program Closed: Alloc: 16c34521 0 And I can't make a breakpoint because this address changes each time I execute the program. Regards, AAbdoh From paul at toddsoftware.com Fri Mar 18 09:12:03 2005 From: paul at toddsoftware.com (Paul Todd) Date: Fri Mar 18 09:10:58 2005 Subject: [Expat-discuss] emulator allocation error In-Reply-To: <20050317075927.E0CE31C001D3@mwinf4011.affiliated.me-wanadoo.net> References: <20050317075927.E0CE31C001D3@mwinf4011.affiliated.me-wanadoo.net> Message-ID: <423A8D53.4040302@toddsoftware.com> You have a memory leak - i.e you are not freeing some memory some where by for example not calling delete. Ashraf Abdoh wrote: >Hi, > >I am working with syExpat as an xml parser; it parses a text and holds it >into a text box, > >But when I press the EXIT button I have the error message: > > > >Program Closed: > >Alloc: 16c34521 > >0 > > > >And I can't make a breakpoint because this address changes each time I >execute the program. > > > > > >Regards, > >AAbdoh > > > >_______________________________________________ >Expat-discuss mailing list >Expat-discuss@libexpat.org >http://mail.libexpat.org/mailman/listinfo/expat-discuss > > > From AAbdoh at informobility.com Sun Mar 20 12:44:56 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Sun Mar 20 13:04:28 2005 Subject: [Expat-discuss] GoogleIt documenation Message-ID: <20050320114352.11A79240048F@mwinf4012.affiliated.me-wanadoo.net> Hi, I got the GoogleIt sample code, but I did not find any documentation for it, I find it hardly to understand. Any one can explain it me, I am still trying to make an xml parser. My question is specific for GoogleQueryParser.cpp and its header. Through the answer I wish to explain the following classes: CGoogleResponseItem, CGoogleResponse, CGoogleResponseError, CGoogleResult, And I wish how it stores the items found assuming that I have multiple items to hold. Regards, Aabdoh. From AAbdoh at informobility.com Tue Mar 22 15:47:48 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Tue Mar 22 15:46:27 2005 Subject: [Expat-discuss] NMAKE fatal error on series 60 Message-ID: <20050322144620.BCD4D24003FF@mwinf4012.affiliated.me-wanadoo.net> I am trying to compile a code on series 60 2.2 on Borland BuilderX IDE, But there is one error message appears without any details: NMAKE : fatal error U1052: file '\Symbian\8.0a\S60_2nd_FP2\EPOC32\BUILD\SYMBIAN\SYEXPAT\FEJJSYM\GROUP\FEJJ\W INS\FEJJ.WINS' not found I searched GOOGLE on it but no use, anyone know about it please tell me. Regards, Ashraf Abdoh. From jpellikk at ee.oulu.fi Thu Mar 24 12:36:29 2005 From: jpellikk at ee.oulu.fi (Jani Pellikka) Date: Thu Mar 24 12:36:31 2005 Subject: [Expat-discuss] CDATA and newlines Message-ID: <20050324113629.GA21379@ee.oulu.fi> Hi, Expat parser seems to remove all newlines and other white space from between the XML tags. I had understood that with CDATA tag all the material inside would be left as it were but even then the parser removes all newlines. Is there any way to preserve all the material inside CDATA tag untouched with Expat parser? -- example -- Unwanted outcome: first line material second line material Wanted outcome: first line material second line material -- example -- Thanks in advance, -- Jani From mark.williams at techop.co.uk Thu Mar 24 17:50:00 2005 From: mark.williams at techop.co.uk (Mark Williams) Date: Thu Mar 24 18:27:48 2005 Subject: [Expat-discuss] CDATA and newlines Message-ID: > -----Original Message----- > From: expat-discuss-bounces@libexpat.org > [mailto:expat-discuss-bounces@libexpat.org] On Behalf Of Jani > Pellikka jpellikk-at-ee.oulu.fi |Expat/1.0-Allow| > Sent: 24 March 2005 11:36 > To: Mark Williams > Subject: [Expat-discuss] CDATA and newlines > > Hi, > > Expat parser seems to remove all newlines and other > white space from between the XML tags. I had understood > that with CDATA tag all the material inside would be left > as it were but even then the parser removes all newlines. > Is there any way to preserve all the material inside CDATA > tag untouched with Expat parser? I had the same issue. Expat is correct -- newlines are not saved in CDATA sections. My solution was to use normal text with character escapes for the newlines. Regards, Mark From rolf at pointsman.de Thu Mar 24 18:53:32 2005 From: rolf at pointsman.de (rolf@pointsman.de) Date: Thu Mar 24 18:57:52 2005 Subject: [Expat-discuss] CDATA and newlines In-Reply-To: Message-ID: <20050324175335.AF65251546@pointsman.pointsman.de> On 24 Mar, Mark Williams wrote: [Jani Pellikka wrote:], >> Expat parser seems to remove all newlines and other >> white space from between the XML tags. I had understood >> that with CDATA tag all the material inside would be left >> as it were but even then the parser removes all newlines. >> Is there any way to preserve all the material inside CDATA >> tag untouched with Expat parser? > > I had the same issue. Expat is correct -- newlines are not saved > in CDATA sections. My solution was to use normal text with character > escapes for the newlines. Err, what? Surely will newlines are reported to the handler (normalized to a line-feed (#xA)). What excat location within the xml recommendation gave you the impression, that newlines within CDATA sections are discarded? And from all what I can tell, expat does this right - I get line-breaks even within CDATA sections. Without seeing his characterDataHandler code I can only guess, why the original poster have its problem. rolf From regis.st-gelais at laubrass.com Thu Mar 24 19:15:14 2005 From: regis.st-gelais at laubrass.com (=?iso-8859-1?Q?R=E9gis_St-Gelais_=28Laubrass=29?=) Date: Thu Mar 24 19:16:25 2005 Subject: [Expat-discuss] CDATA and newlines References: <20050324113629.GA21379@ee.oulu.fi> Message-ID: <010301c5309d$6ded15a0$6400a8c0@laubrasssag1> ----- Original Message ----- From: Jani Pellikka To: expat-discuss@libexpat.org Sent: Thursday, March 24, 2005 6:36 AM Subject: [Expat-discuss] CDATA and newlines >Hi, > >Expat parser seems to remove all newlines and other >white space from between the XML tags. I had understood >that with CDATA tag all the material inside would be left >as it were but even then the parser removes all newlines. >Is there any way to preserve all the material inside CDATA >tag untouched with Expat parser? This was discused in november 2003. Infact all CRs (and CRLF pairs) are converted into single LF. This is something that all conformant parsers do, I believe even MSXML does this. There might be some setting in parser that preserves CRs or there might not. So you must handle these at application level. Sometimes you can just work with (unix) style LFs, usually this isn't possible when working in windows and you want to "visualize" your data to the user though. So you need to convert them to CRLFs, nasty job, I know. see XML 1.0 spec http://www.xml.com/axml/target.html#sec-line-ends Here is what I do: I my data section I replace CR and LF at save time by other caracteres that wont be used and back to CR ou LF at reading time. Regis From AAbdoh at informobility.com Sun Mar 27 14:26:27 2005 From: AAbdoh at informobility.com (Ashraf Abdoh) Date: Sun Mar 27 14:57:48 2005 Subject: [Expat-discuss] Porting GoogleIt to Series60 Message-ID: <20050327122530.3B8D62400383@mwinf4012.affiliated.me-wanadoo.net> Hi, Any one can help me in porting GoogleIt Example to Series60 platform, This sample implements the syExpat parser on Symbian but it needs the UIQ, and I am using the Series60 Platform. I spent much time trying to use it!!! Thanks in advance From oswal at amazon.com Mon Mar 28 07:34:57 2005 From: oswal at amazon.com (Oswal, Sachin) Date: Mon Mar 28 07:35:01 2005 Subject: [Expat-discuss] XML Document Parse Error: not well-formed line Message-ID: Hello All, I'm using Expat to parse xml information involving the Japanese language. The expat version and error details are as follows - Expat Version - 1.95.5 Error - XML Document Parse Error: (0)not well-formed line: 58 column: 33 byte: 2295 I couldn't find out what exact character is causing the parser to fail. I think its some form of a '-'. 1.95.5 is an old version and we would like to upgrade to a later version. Does anyone recall if there were any fixes related to the above error that were rolled out in versions after 1.95.5. If yes which one? Also, which one of the latest versions is the most stable and reliable version to use. I've looked through the bug list here http://sourceforge.net/tracker/?group_id=10127&atid=110127 and through the change list here http://expat.sourceforge.net/ but didn't come across any fixes related to the above issue. Any response will be appreciated. Thanks Sachin From karl at waclawek.net Mon Mar 28 15:57:59 2005 From: karl at waclawek.net (Karl Waclawek) Date: Mon Mar 28 15:58:09 2005 Subject: [Expat-discuss] XML Document Parse Error: not well-formed line In-Reply-To: References: Message-ID: <42480D67.2020900@waclawek.net> Oswal, Sachin wrote: > Hello All, > I'm using Expat to parse xml information involving the Japanese language. The expat version and error details are as follows - > Expat Version - 1.95.5 > Error - XML Document Parse Error: (0)not well-formed line: 58 column: 33 byte: 2295 > > I couldn't find out what exact character is causing the parser to fail. I think its some form of a '-'. > > 1.95.5 is an old version and we would like to upgrade to a later version. Does anyone recall if > there were any fixes related to the above error that were rolled out in versions after 1.95.5. If yes which one? > Also, which one of the latest versions is the most stable and reliable version to use. The latest is the best. > I've looked through the bug list here http://sourceforge.net/tracker/?group_id=10127&atid=110127 > and through the change list here http://expat.sourceforge.net/ but didn't come across any fixes related to the above issue. > This may very well be because the document is not well-formed. Are you 100% sure the document is correct? Karl From oswal at amazon.com Thu Mar 31 09:56:44 2005 From: oswal at amazon.com (Oswal, Sachin) Date: Thu Mar 31 09:56:59 2005 Subject: [Expat-discuss] RE: Expat-discuss Digest, Vol 60, Issue 14 Message-ID: Thanks for the response Karl. I'm not sure about the document. Its Japanese and I couldn't make sure if the all characters in that string are valid. I'm going to test with the latest version. Will let you know how it goes. Sachin -----Original Message----- Date: Mon, 28 Mar 2005 08:57:59 -0500 From: Karl Waclawek Subject: Re: [Expat-discuss] XML Document Parse Error: not well-formed line To: expat-discuss@libexpat.org Message-ID: <42480D67.2020900@waclawek.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Oswal, Sachin wrote: > Hello All, > I'm using Expat to parse xml information involving the Japanese language. The expat version and error details are as follows - > Expat Version - 1.95.5 > Error - XML Document Parse Error: (0)not well-formed line: 58 column: 33 byte: 2295 > > I couldn't find out what exact character is causing the parser to fail. I think its some form of a '-'. > > 1.95.5 is an old version and we would like to upgrade to a later version. Does anyone recall if > there were any fixes related to the above error that were rolled out in versions after 1.95.5. If yes which one? > Also, which one of the latest versions is the most stable and reliable version to use. The latest is the best. > I've looked through the bug list here http://sourceforge.net/tracker/?group_id=10127&atid=110127 > and through the change list here http://expat.sourceforge.net/ but didn't come across any fixes related to the above issue. > This may very well be because the document is not well-formed. Are you 100% sure the document is correct? Karl