Re: [xml] Entity reference Problem



On Wed, Apr 25, 2007 at 03:29:36PM +0200, Shirazi Babak wrote:
    doc = xmlSAXParseFileWithData(&sax, stpI->szFilename, 0, (void
*)stpI);

....

So
How could I turn on 
"...entities substitution at the parser level."
In this situation? 

  Do *NOT* use SAX if you're not able to do minimal debugging and tweaking
on your own. Why did you choose to use SAX ? I usually strongly suggest to
newbies to not try to use it !
  You can try:
    - get the parser context and set ctxt->replaceEntities to 1
      this may require to use another API
    - http://xmlsoft.org/html/libxml-parser.html#xmlSubstituteEntitiesDefault
      which is bad because it change the default globally for the library

Daniel


-- 
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard      | virtualization library  http://libvirt.org/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine  http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]