Re: [xml] htmlReadMemory

On Wed, Jan 26, 2005 at 10:50:39AM -0000, spinmar interfree it wrote:

Hi all,
I have two questions regards to htmlReadMemory.
This function is 

htmlDocPtr    htmlReadMemory (const char * buffer, int size, const char * URL, const char * encoding, int 

I don't understand the meaning of:

URL: the base URL to use for the document

For example if the url is, what's the base URL?

The second question is about encoding. I have a buffer with my html code: can I pass it to htmlReadMemory 
with encoding=NULL and hope that it automatically discovers the rigth encoding of the page?


If I use HTML_PARSE_NOERROR | HTML_PARSE_NOWARNING as options, the non well formed errors are suppresed?

  depends how you built your errror layer. Some errors like memory allocation
errors will always be reported anyway.


Daniel Veillard      | Red Hat Desktop team
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

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