blob: aee67d061b58b4f92501350b5a46b8ef8a1ad2b0 [file] [log] [blame]
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001<HTML
2><HEAD
3><TITLE
4>HTMLparser</TITLE
5><META
6NAME="GENERATOR"
7CONTENT="Modular DocBook HTML Stylesheet Version 1.33"><LINK
8REL="HOME"
9TITLE="Gnome XML Library Reference Manual"
10HREF="book1.html"><LINK
11REL="UP"
Daniel Veillard35008381999-10-25 13:15:52 +000012TITLE="Libxml Library Reference"
13HREF="libxml-lib.html"><LINK
Daniel Veillard1566d3a1999-07-15 14:24:29 +000014REL="PREVIOUS"
Daniel Veillard6bd26dc1999-09-03 14:28:40 +000015TITLE="xml-error"
16HREF="gnome-xml-xml-error.html"><LINK
Daniel Veillard1566d3a1999-07-15 14:24:29 +000017REL="NEXT"
18TITLE="HTMLtree"
19HREF="gnome-xml-htmltree.html"></HEAD
20><BODY
21BGCOLOR="#FFFFFF"
22TEXT="#000000"
23><DIV
24CLASS="NAVHEADER"
25><TABLE
26WIDTH="100%"
27BORDER="0"
28BGCOLOR="#000000"
29CELLPADDING="1"
30CELLSPACING="0"
31><TR
32><TH
33COLSPAN="4"
34ALIGN="center"
35><FONT
36COLOR="#FFFFFF"
37SIZE="5"
38>Gnome XML Library Reference Manual</FONT
39></TH
40></TR
41><TR
42><TD
43WIDTH="25%"
44BGCOLOR="#C00000"
45ALIGN="left"
46><A
Daniel Veillard6bd26dc1999-09-03 14:28:40 +000047HREF="gnome-xml-xml-error.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +000048><FONT
49COLOR="#FFFFFF"
50SIZE="3"
51><B
52>&#60;&#60;&#60; Previous Page</B
53></FONT
54></A
55></TD
56><TD
57WIDTH="25%"
58BGCOLOR="#0000C0"
59ALIGN="center"
60><FONT
61COLOR="#FFFFFF"
62SIZE="3"
63><B
64><A
65HREF="book1.html"
66><FONT
67COLOR="#FFFFFF"
68SIZE="3"
69><B
70>Home</B
71></FONT
72></A
73></B
74></FONT
75></TD
76><TD
77WIDTH="25%"
78BGCOLOR="#00C000"
79ALIGN="center"
80><FONT
81COLOR="#FFFFFF"
82SIZE="3"
83><B
84><A
Daniel Veillard35008381999-10-25 13:15:52 +000085HREF="libxml-lib.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +000086><FONT
87COLOR="#FFFFFF"
88SIZE="3"
89><B
90>Up</B
91></FONT
92></A
93></B
94></FONT
95></TD
96><TD
97WIDTH="25%"
98BGCOLOR="#C00000"
99ALIGN="right"
100><A
101HREF="gnome-xml-htmltree.html"
102><FONT
103COLOR="#FFFFFF"
104SIZE="3"
105><B
106>Next Page &#62;&#62;&#62;</B
107></FONT
108></A
109></TD
110></TR
111></TABLE
112></DIV
113><H1
114>HTMLparser</H1
115><DIV
116CLASS="REFNAMEDIV"
117><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000118NAME="AEN7842"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000119></A
120><H2
121>Name</H2
122>HTMLparser &#8212; </DIV
123><DIV
124CLASS="REFSYNOPSISDIV"
125><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000126NAME="AEN7845"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000127></A
128><H2
129>Synopsis</H2
130><TABLE
131BORDER="0"
132BGCOLOR="#D6E8FF"
133WIDTH="100%"
134CELLPADDING="6"
135><TR
136><TD
137><PRE
138CLASS="SYNOPSIS"
139>&#13;
140
141typedef <A
142HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXT"
143>htmlParserCtxt</A
144>;
145typedef <A
146HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
147>htmlParserCtxtPtr</A
148>;
149typedef <A
150HREF="gnome-xml-htmlparser.html#HTMLPARSERNODEINFO"
151>htmlParserNodeInfo</A
152>;
153typedef <A
154HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLER"
155>htmlSAXHandler</A
156>;
157typedef <A
158HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
159>htmlSAXHandlerPtr</A
160>;
161typedef <A
162HREF="gnome-xml-htmlparser.html#HTMLPARSERINPUT"
163>htmlParserInput</A
164>;
165typedef <A
166HREF="gnome-xml-htmlparser.html#HTMLPARSERINPUTPTR"
167>htmlParserInputPtr</A
168>;
169typedef <A
170HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
171>htmlDocPtr</A
172>;
173typedef <A
174HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
175>htmlNodePtr</A
176>;
177<GTKDOCLINK
178HREF="HTMLELEMDESCPTR"
179>htmlElemDescPtr</GTKDOCLINK
180> <A
181HREF="gnome-xml-htmlparser.html#HTMLTAGLOOKUP"
182>htmlTagLookup</A
183> (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000184HREF="gnome-xml-tree.html#XMLCHAR"
185>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000186> *tag);
187<GTKDOCLINK
188HREF="HTMLENTITYDESCPTR"
189>htmlEntityDescPtr</GTKDOCLINK
190> <A
191HREF="gnome-xml-htmlparser.html#HTMLENTITYLOOKUP"
192>htmlEntityLookup</A
193> (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000194HREF="gnome-xml-tree.html#XMLCHAR"
195>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000196> *name);
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000197int <A
198HREF="gnome-xml-htmlparser.html#HTMLISAUTOCLOSED"
199>htmlIsAutoClosed</A
200> (<A
201HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
202>htmlDocPtr</A
203> doc,
204 <A
205HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
206>htmlNodePtr</A
207> elem);
208int <A
209HREF="gnome-xml-htmlparser.html#HTMLAUTOCLOSETAG"
210>htmlAutoCloseTag</A
211> (<A
212HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
213>htmlDocPtr</A
214> doc,
215 const <A
216HREF="gnome-xml-tree.html#XMLCHAR"
217>xmlChar</A
218> *name,
219 <A
220HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
221>htmlNodePtr</A
222> elem);
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000223<GTKDOCLINK
224HREF="HTMLENTITYDESCPTR"
225>htmlEntityDescPtr</GTKDOCLINK
226> <A
227HREF="gnome-xml-htmlparser.html#HTMLPARSEENTITYREF"
228>htmlParseEntityRef</A
229> (<A
230HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
231>htmlParserCtxtPtr</A
232> ctxt,
233 <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000234HREF="gnome-xml-tree.html#XMLCHAR"
235>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000236> **str);
237int <A
238HREF="gnome-xml-htmlparser.html#HTMLPARSECHARREF"
239>htmlParseCharRef</A
240> (<A
241HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
242>htmlParserCtxtPtr</A
243> ctxt);
244void <A
245HREF="gnome-xml-htmlparser.html#HTMLPARSEELEMENT"
246>htmlParseElement</A
247> (<A
248HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
249>htmlParserCtxtPtr</A
250> ctxt);
251<A
252HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
253>htmlDocPtr</A
254> <A
255HREF="gnome-xml-htmlparser.html#HTMLSAXPARSEDOC"
256>htmlSAXParseDoc</A
257> (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000258HREF="gnome-xml-tree.html#XMLCHAR"
259>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000260> *cur,
261 const char *encoding,
262 <A
263HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
264>htmlSAXHandlerPtr</A
265> sax,
266 void *userData);
267<A
268HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
269>htmlDocPtr</A
270> <A
271HREF="gnome-xml-htmlparser.html#HTMLPARSEDOC"
272>htmlParseDoc</A
273> (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000274HREF="gnome-xml-tree.html#XMLCHAR"
275>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000276> *cur,
277 const char *encoding);
278<A
279HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
280>htmlDocPtr</A
281> <A
282HREF="gnome-xml-htmlparser.html#HTMLSAXPARSEFILE"
283>htmlSAXParseFile</A
284> (const char *filename,
285 const char *encoding,
286 <A
287HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
288>htmlSAXHandlerPtr</A
289> sax,
290 void *userData);
291<A
292HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
293>htmlDocPtr</A
294> <A
295HREF="gnome-xml-htmlparser.html#HTMLPARSEFILE"
296>htmlParseFile</A
297> (const char *filename,
298 const char *encoding);</PRE
299></TD
300></TR
301></TABLE
302></DIV
303><DIV
304CLASS="REFSECT1"
305><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000306NAME="AEN7890"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000307></A
308><H2
309>Description</H2
310><P
311></P
312></DIV
313><DIV
314CLASS="REFSECT1"
315><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000316NAME="AEN7893"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000317></A
318><H2
319>Details</H2
320><DIV
321CLASS="REFSECT2"
322><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000323NAME="AEN7895"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000324></A
325><H3
326><A
327NAME="HTMLPARSERCTXT"
328></A
329>htmlParserCtxt</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000330><TABLE
331BORDER="0"
332BGCOLOR="#D6E8FF"
333WIDTH="100%"
334CELLPADDING="6"
335><TR
336><TD
337><PRE
338CLASS="PROGRAMLISTING"
339>typedef xmlParserCtxt htmlParserCtxt;</PRE
340></TD
341></TR
342></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000343><P
344></P
345></DIV
346><HR><DIV
347CLASS="REFSECT2"
348><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000349NAME="AEN7900"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000350></A
351><H3
352><A
353NAME="HTMLPARSERCTXTPTR"
354></A
355>htmlParserCtxtPtr</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000356><TABLE
357BORDER="0"
358BGCOLOR="#D6E8FF"
359WIDTH="100%"
360CELLPADDING="6"
361><TR
362><TD
363><PRE
364CLASS="PROGRAMLISTING"
365>typedef xmlParserCtxtPtr htmlParserCtxtPtr;</PRE
366></TD
367></TR
368></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000369><P
370></P
371></DIV
372><HR><DIV
373CLASS="REFSECT2"
374><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000375NAME="AEN7905"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000376></A
377><H3
378><A
379NAME="HTMLPARSERNODEINFO"
380></A
381>htmlParserNodeInfo</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000382><TABLE
383BORDER="0"
384BGCOLOR="#D6E8FF"
385WIDTH="100%"
386CELLPADDING="6"
387><TR
388><TD
389><PRE
390CLASS="PROGRAMLISTING"
391>typedef xmlParserNodeInfo htmlParserNodeInfo;</PRE
392></TD
393></TR
394></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000395><P
396></P
397></DIV
398><HR><DIV
399CLASS="REFSECT2"
400><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000401NAME="AEN7910"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000402></A
403><H3
404><A
405NAME="HTMLSAXHANDLER"
406></A
407>htmlSAXHandler</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000408><TABLE
409BORDER="0"
410BGCOLOR="#D6E8FF"
411WIDTH="100%"
412CELLPADDING="6"
413><TR
414><TD
415><PRE
416CLASS="PROGRAMLISTING"
417>typedef xmlSAXHandler htmlSAXHandler;</PRE
418></TD
419></TR
420></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000421><P
422></P
423></DIV
424><HR><DIV
425CLASS="REFSECT2"
426><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000427NAME="AEN7915"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000428></A
429><H3
430><A
431NAME="HTMLSAXHANDLERPTR"
432></A
433>htmlSAXHandlerPtr</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000434><TABLE
435BORDER="0"
436BGCOLOR="#D6E8FF"
437WIDTH="100%"
438CELLPADDING="6"
439><TR
440><TD
441><PRE
442CLASS="PROGRAMLISTING"
443>typedef xmlSAXHandlerPtr htmlSAXHandlerPtr;</PRE
444></TD
445></TR
446></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000447><P
448></P
449></DIV
450><HR><DIV
451CLASS="REFSECT2"
452><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000453NAME="AEN7920"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000454></A
455><H3
456><A
457NAME="HTMLPARSERINPUT"
458></A
459>htmlParserInput</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000460><TABLE
461BORDER="0"
462BGCOLOR="#D6E8FF"
463WIDTH="100%"
464CELLPADDING="6"
465><TR
466><TD
467><PRE
468CLASS="PROGRAMLISTING"
469>typedef xmlParserInput htmlParserInput;</PRE
470></TD
471></TR
472></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000473><P
474></P
475></DIV
476><HR><DIV
477CLASS="REFSECT2"
478><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000479NAME="AEN7925"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000480></A
481><H3
482><A
483NAME="HTMLPARSERINPUTPTR"
484></A
485>htmlParserInputPtr</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000486><TABLE
487BORDER="0"
488BGCOLOR="#D6E8FF"
489WIDTH="100%"
490CELLPADDING="6"
491><TR
492><TD
493><PRE
494CLASS="PROGRAMLISTING"
495>typedef xmlParserInputPtr htmlParserInputPtr;</PRE
496></TD
497></TR
498></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000499><P
500></P
501></DIV
502><HR><DIV
503CLASS="REFSECT2"
504><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000505NAME="AEN7930"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000506></A
507><H3
508><A
509NAME="HTMLDOCPTR"
510></A
511>htmlDocPtr</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000512><TABLE
513BORDER="0"
514BGCOLOR="#D6E8FF"
515WIDTH="100%"
516CELLPADDING="6"
517><TR
518><TD
519><PRE
520CLASS="PROGRAMLISTING"
521>typedef xmlDocPtr htmlDocPtr;</PRE
522></TD
523></TR
524></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000525><P
526></P
527></DIV
528><HR><DIV
529CLASS="REFSECT2"
530><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000531NAME="AEN7935"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000532></A
533><H3
534><A
535NAME="HTMLNODEPTR"
536></A
537>htmlNodePtr</H3
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000538><TABLE
539BORDER="0"
540BGCOLOR="#D6E8FF"
541WIDTH="100%"
542CELLPADDING="6"
543><TR
544><TD
545><PRE
546CLASS="PROGRAMLISTING"
547>typedef xmlNodePtr htmlNodePtr;</PRE
548></TD
549></TR
550></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000551><P
552></P
553></DIV
554><HR><DIV
555CLASS="REFSECT2"
556><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000557NAME="AEN7940"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000558></A
559><H3
560><A
561NAME="HTMLTAGLOOKUP"
562></A
563>htmlTagLookup ()</H3
564><TABLE
565BORDER="0"
566BGCOLOR="#D6E8FF"
567WIDTH="100%"
568CELLPADDING="6"
569><TR
570><TD
571><PRE
572CLASS="PROGRAMLISTING"
573><GTKDOCLINK
574HREF="HTMLELEMDESCPTR"
575>htmlElemDescPtr</GTKDOCLINK
576> htmlTagLookup (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000577HREF="gnome-xml-tree.html#XMLCHAR"
578>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000579> *tag);</PRE
580></TD
581></TR
582></TABLE
583><P
584>Lookup the HTML tag in the ElementTable</P
585><P
586></P
587><DIV
588CLASS="INFORMALTABLE"
589><P
590></P
591><TABLE
592BORDER="0"
593WIDTH="100%"
594BGCOLOR="#FFD0D0"
595CELLSPACING="0"
596CELLPADDING="4"
597CLASS="CALSTABLE"
598><TR
599><TD
600WIDTH="20%"
601ALIGN="RIGHT"
602VALIGN="TOP"
603><TT
604CLASS="PARAMETER"
605><I
606>tag</I
607></TT
608>&nbsp;:</TD
609><TD
610WIDTH="80%"
611ALIGN="LEFT"
612VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000613> The tag name</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000614></TR
615><TR
616><TD
617WIDTH="20%"
618ALIGN="RIGHT"
619VALIGN="TOP"
620><I
621CLASS="EMPHASIS"
622>Returns</I
623> :</TD
624><TD
625WIDTH="80%"
626ALIGN="LEFT"
627VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000628>the related htmlElemDescPtr or NULL if not found.</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000629></TR
630></TABLE
631><P
632></P
633></DIV
634></DIV
635><HR><DIV
636CLASS="REFSECT2"
637><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000638NAME="AEN7961"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000639></A
640><H3
641><A
642NAME="HTMLENTITYLOOKUP"
643></A
644>htmlEntityLookup ()</H3
645><TABLE
646BORDER="0"
647BGCOLOR="#D6E8FF"
648WIDTH="100%"
649CELLPADDING="6"
650><TR
651><TD
652><PRE
653CLASS="PROGRAMLISTING"
654><GTKDOCLINK
655HREF="HTMLENTITYDESCPTR"
656>htmlEntityDescPtr</GTKDOCLINK
657> htmlEntityLookup (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000658HREF="gnome-xml-tree.html#XMLCHAR"
659>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000660> *name);</PRE
661></TD
662></TR
663></TABLE
664><P
665>Lookup the given entity in EntitiesTable</P
666><P
667>TODO: the linear scan is really ugly, an hash table is really needed.</P
668><P
669></P
670><DIV
671CLASS="INFORMALTABLE"
672><P
673></P
674><TABLE
675BORDER="0"
676WIDTH="100%"
677BGCOLOR="#FFD0D0"
678CELLSPACING="0"
679CELLPADDING="4"
680CLASS="CALSTABLE"
681><TR
682><TD
683WIDTH="20%"
684ALIGN="RIGHT"
685VALIGN="TOP"
686><TT
687CLASS="PARAMETER"
688><I
689>name</I
690></TT
691>&nbsp;:</TD
692><TD
693WIDTH="80%"
694ALIGN="LEFT"
695VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000696> the entity name</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000697></TR
698><TR
699><TD
700WIDTH="20%"
701ALIGN="RIGHT"
702VALIGN="TOP"
703><I
704CLASS="EMPHASIS"
705>Returns</I
706> :</TD
707><TD
708WIDTH="80%"
709ALIGN="LEFT"
710VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000711>the associated htmlEntityDescPtr if found, NULL otherwise.</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000712></TR
713></TABLE
714><P
715></P
716></DIV
717></DIV
718><HR><DIV
719CLASS="REFSECT2"
720><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000721NAME="AEN7983"
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000722></A
723><H3
724><A
725NAME="HTMLISAUTOCLOSED"
726></A
727>htmlIsAutoClosed ()</H3
728><TABLE
729BORDER="0"
730BGCOLOR="#D6E8FF"
731WIDTH="100%"
732CELLPADDING="6"
733><TR
734><TD
735><PRE
736CLASS="PROGRAMLISTING"
737>int htmlIsAutoClosed (<A
738HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
739>htmlDocPtr</A
740> doc,
741 <A
742HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
743>htmlNodePtr</A
744> elem);</PRE
745></TD
746></TR
747></TABLE
748><P
749>The HTmL DtD allows a tag to implicitely close other tags.
750The list is kept in htmlStartClose array. This function checks
751if a tag is autoclosed by one of it's child</P
752><P
753></P
754><DIV
755CLASS="INFORMALTABLE"
756><P
757></P
758><TABLE
759BORDER="0"
760WIDTH="100%"
761BGCOLOR="#FFD0D0"
762CELLSPACING="0"
763CELLPADDING="4"
764CLASS="CALSTABLE"
765><TR
766><TD
767WIDTH="20%"
768ALIGN="RIGHT"
769VALIGN="TOP"
770><TT
771CLASS="PARAMETER"
772><I
773>doc</I
774></TT
775>&nbsp;:</TD
776><TD
777WIDTH="80%"
778ALIGN="LEFT"
779VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000780> the HTML document</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000781></TR
782><TR
783><TD
784WIDTH="20%"
785ALIGN="RIGHT"
786VALIGN="TOP"
787><TT
788CLASS="PARAMETER"
789><I
790>elem</I
791></TT
792>&nbsp;:</TD
793><TD
794WIDTH="80%"
795ALIGN="LEFT"
796VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000797> the HTML element</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000798></TR
799><TR
800><TD
801WIDTH="20%"
802ALIGN="RIGHT"
803VALIGN="TOP"
804><I
805CLASS="EMPHASIS"
806>Returns</I
807> :</TD
808><TD
809WIDTH="80%"
810ALIGN="LEFT"
811VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000812>1 if autoclosed, 0 otherwise</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000813></TR
814></TABLE
815><P
816></P
817></DIV
818></DIV
819><HR><DIV
820CLASS="REFSECT2"
821><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000822NAME="AEN8008"
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000823></A
824><H3
825><A
826NAME="HTMLAUTOCLOSETAG"
827></A
828>htmlAutoCloseTag ()</H3
829><TABLE
830BORDER="0"
831BGCOLOR="#D6E8FF"
832WIDTH="100%"
833CELLPADDING="6"
834><TR
835><TD
836><PRE
837CLASS="PROGRAMLISTING"
838>int htmlAutoCloseTag (<A
839HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
840>htmlDocPtr</A
841> doc,
842 const <A
843HREF="gnome-xml-tree.html#XMLCHAR"
844>xmlChar</A
845> *name,
846 <A
847HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
848>htmlNodePtr</A
849> elem);</PRE
850></TD
851></TR
852></TABLE
853><P
854>The HTmL DtD allows a tag to implicitely close other tags.
855The list is kept in htmlStartClose array. This function checks
856if the element or one of it's children would autoclose the
857given tag.</P
858><P
859></P
860><DIV
861CLASS="INFORMALTABLE"
862><P
863></P
864><TABLE
865BORDER="0"
866WIDTH="100%"
867BGCOLOR="#FFD0D0"
868CELLSPACING="0"
869CELLPADDING="4"
870CLASS="CALSTABLE"
871><TR
872><TD
873WIDTH="20%"
874ALIGN="RIGHT"
875VALIGN="TOP"
876><TT
877CLASS="PARAMETER"
878><I
879>doc</I
880></TT
881>&nbsp;:</TD
882><TD
883WIDTH="80%"
884ALIGN="LEFT"
885VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000886> the HTML document</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000887></TR
888><TR
889><TD
890WIDTH="20%"
891ALIGN="RIGHT"
892VALIGN="TOP"
893><TT
894CLASS="PARAMETER"
895><I
896>name</I
897></TT
898>&nbsp;:</TD
899><TD
900WIDTH="80%"
901ALIGN="LEFT"
902VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000903> The tag name</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000904></TR
905><TR
906><TD
907WIDTH="20%"
908ALIGN="RIGHT"
909VALIGN="TOP"
910><TT
911CLASS="PARAMETER"
912><I
913>elem</I
914></TT
915>&nbsp;:</TD
916><TD
917WIDTH="80%"
918ALIGN="LEFT"
919VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000920> the HTML element</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000921></TR
922><TR
923><TD
924WIDTH="20%"
925ALIGN="RIGHT"
926VALIGN="TOP"
927><I
928CLASS="EMPHASIS"
929>Returns</I
930> :</TD
931><TD
932WIDTH="80%"
933ALIGN="LEFT"
934VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000935>1 if autoclose, 0 otherwise</TD
Daniel Veillard5cb5ab81999-12-21 15:35:29 +0000936></TR
937></TABLE
938><P
939></P
940></DIV
941></DIV
942><HR><DIV
943CLASS="REFSECT2"
944><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +0000945NAME="AEN8038"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000946></A
947><H3
948><A
949NAME="HTMLPARSEENTITYREF"
950></A
951>htmlParseEntityRef ()</H3
952><TABLE
953BORDER="0"
954BGCOLOR="#D6E8FF"
955WIDTH="100%"
956CELLPADDING="6"
957><TR
958><TD
959><PRE
960CLASS="PROGRAMLISTING"
961><GTKDOCLINK
962HREF="HTMLENTITYDESCPTR"
963>htmlEntityDescPtr</GTKDOCLINK
964> htmlParseEntityRef (<A
965HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
966>htmlParserCtxtPtr</A
967> ctxt,
968 <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000969HREF="gnome-xml-tree.html#XMLCHAR"
970>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000971> **str);</PRE
972></TD
973></TR
974></TABLE
975><P
976>parse an HTML ENTITY references</P
977><P
978>[68] EntityRef ::= '&amp;' Name ';'</P
979><P
980></P
981><DIV
982CLASS="INFORMALTABLE"
983><P
984></P
985><TABLE
986BORDER="0"
987WIDTH="100%"
988BGCOLOR="#FFD0D0"
989CELLSPACING="0"
990CELLPADDING="4"
991CLASS="CALSTABLE"
992><TR
993><TD
994WIDTH="20%"
995ALIGN="RIGHT"
996VALIGN="TOP"
997><TT
998CLASS="PARAMETER"
999><I
1000>ctxt</I
1001></TT
1002>&nbsp;:</TD
1003><TD
1004WIDTH="80%"
1005ALIGN="LEFT"
1006VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001007> an HTML parser context</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001008></TR
1009><TR
1010><TD
1011WIDTH="20%"
1012ALIGN="RIGHT"
1013VALIGN="TOP"
1014><TT
1015CLASS="PARAMETER"
1016><I
1017>str</I
1018></TT
1019>&nbsp;:</TD
1020><TD
1021WIDTH="80%"
1022ALIGN="LEFT"
1023VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001024> location to store the entity name</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001025></TR
1026><TR
1027><TD
1028WIDTH="20%"
1029ALIGN="RIGHT"
1030VALIGN="TOP"
1031><I
1032CLASS="EMPHASIS"
1033>Returns</I
1034> :</TD
1035><TD
1036WIDTH="80%"
1037ALIGN="LEFT"
1038VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001039>the associated htmlEntityDescPtr if found, or NULL otherwise,
1040if non-NULL *str will have to be freed by the caller.</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001041></TR
1042></TABLE
1043><P
1044></P
1045></DIV
1046></DIV
1047><HR><DIV
1048CLASS="REFSECT2"
1049><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001050NAME="AEN8065"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001051></A
1052><H3
1053><A
1054NAME="HTMLPARSECHARREF"
1055></A
1056>htmlParseCharRef ()</H3
1057><TABLE
1058BORDER="0"
1059BGCOLOR="#D6E8FF"
1060WIDTH="100%"
1061CELLPADDING="6"
1062><TR
1063><TD
1064><PRE
1065CLASS="PROGRAMLISTING"
1066>int htmlParseCharRef (<A
1067HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
1068>htmlParserCtxtPtr</A
1069> ctxt);</PRE
1070></TD
1071></TR
1072></TABLE
1073><P
1074>parse Reference declarations</P
1075><P
1076>[66] CharRef ::= '&amp;#' [0-9]+ ';' |
1077'&amp;<GTKDOCLINK
1078HREF="X"
1079>x</GTKDOCLINK
1080>' [0-9a-fA-F]+ ';'</P
1081><P
1082></P
1083><DIV
1084CLASS="INFORMALTABLE"
1085><P
1086></P
1087><TABLE
1088BORDER="0"
1089WIDTH="100%"
1090BGCOLOR="#FFD0D0"
1091CELLSPACING="0"
1092CELLPADDING="4"
1093CLASS="CALSTABLE"
1094><TR
1095><TD
1096WIDTH="20%"
1097ALIGN="RIGHT"
1098VALIGN="TOP"
1099><TT
1100CLASS="PARAMETER"
1101><I
1102>ctxt</I
1103></TT
1104>&nbsp;:</TD
1105><TD
1106WIDTH="80%"
1107ALIGN="LEFT"
1108VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001109> an HTML parser context</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001110></TR
1111><TR
1112><TD
1113WIDTH="20%"
1114ALIGN="RIGHT"
1115VALIGN="TOP"
1116><I
1117CLASS="EMPHASIS"
1118>Returns</I
1119> :</TD
1120><TD
1121WIDTH="80%"
1122ALIGN="LEFT"
1123VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001124>the value parsed (as an int)</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001125></TR
1126></TABLE
1127><P
1128></P
1129></DIV
1130></DIV
1131><HR><DIV
1132CLASS="REFSECT2"
1133><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001134NAME="AEN8087"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001135></A
1136><H3
1137><A
1138NAME="HTMLPARSEELEMENT"
1139></A
1140>htmlParseElement ()</H3
1141><TABLE
1142BORDER="0"
1143BGCOLOR="#D6E8FF"
1144WIDTH="100%"
1145CELLPADDING="6"
1146><TR
1147><TD
1148><PRE
1149CLASS="PROGRAMLISTING"
1150>void htmlParseElement (<A
1151HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
1152>htmlParserCtxtPtr</A
1153> ctxt);</PRE
1154></TD
1155></TR
1156></TABLE
1157><P
1158>parse an HTML element, this is highly recursive</P
1159><P
1160>[39] element ::= EmptyElemTag | STag content ETag</P
1161><P
1162>[41] Attribute ::= Name Eq AttValue</P
1163><P
1164></P
1165><DIV
1166CLASS="INFORMALTABLE"
1167><P
1168></P
1169><TABLE
1170BORDER="0"
1171WIDTH="100%"
1172BGCOLOR="#FFD0D0"
1173CELLSPACING="0"
1174CELLPADDING="4"
1175CLASS="CALSTABLE"
1176><TR
1177><TD
1178WIDTH="20%"
1179ALIGN="RIGHT"
1180VALIGN="TOP"
1181><TT
1182CLASS="PARAMETER"
1183><I
1184>ctxt</I
1185></TT
1186>&nbsp;:</TD
1187><TD
1188WIDTH="80%"
1189ALIGN="LEFT"
1190VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001191> an HTML parser context</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001192></TR
1193></TABLE
1194><P
1195></P
1196></DIV
1197></DIV
1198><HR><DIV
1199CLASS="REFSECT2"
1200><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001201NAME="AEN8105"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001202></A
1203><H3
1204><A
1205NAME="HTMLSAXPARSEDOC"
1206></A
1207>htmlSAXParseDoc ()</H3
1208><TABLE
1209BORDER="0"
1210BGCOLOR="#D6E8FF"
1211WIDTH="100%"
1212CELLPADDING="6"
1213><TR
1214><TD
1215><PRE
1216CLASS="PROGRAMLISTING"
1217><A
1218HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1219>htmlDocPtr</A
1220> htmlSAXParseDoc (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +00001221HREF="gnome-xml-tree.html#XMLCHAR"
1222>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001223> *cur,
1224 const char *encoding,
1225 <A
1226HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
1227>htmlSAXHandlerPtr</A
1228> sax,
1229 void *userData);</PRE
1230></TD
1231></TR
1232></TABLE
1233><P
1234>parse an HTML in-memory document and build a tree.
1235It use the given SAX function block to handle the parsing callback.
1236If sax is NULL, fallback to the default DOM tree building routines.</P
1237><P
1238></P
1239><DIV
1240CLASS="INFORMALTABLE"
1241><P
1242></P
1243><TABLE
1244BORDER="0"
1245WIDTH="100%"
1246BGCOLOR="#FFD0D0"
1247CELLSPACING="0"
1248CELLPADDING="4"
1249CLASS="CALSTABLE"
1250><TR
1251><TD
1252WIDTH="20%"
1253ALIGN="RIGHT"
1254VALIGN="TOP"
1255><TT
1256CLASS="PARAMETER"
1257><I
1258>cur</I
1259></TT
1260>&nbsp;:</TD
1261><TD
1262WIDTH="80%"
1263ALIGN="LEFT"
1264VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001265> a pointer to an array of xmlChar</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001266></TR
1267><TR
1268><TD
1269WIDTH="20%"
1270ALIGN="RIGHT"
1271VALIGN="TOP"
1272><TT
1273CLASS="PARAMETER"
1274><I
1275>encoding</I
1276></TT
1277>&nbsp;:</TD
1278><TD
1279WIDTH="80%"
1280ALIGN="LEFT"
1281VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001282> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001283></TR
1284><TR
1285><TD
1286WIDTH="20%"
1287ALIGN="RIGHT"
1288VALIGN="TOP"
1289><TT
1290CLASS="PARAMETER"
1291><I
1292>sax</I
1293></TT
1294>&nbsp;:</TD
1295><TD
1296WIDTH="80%"
1297ALIGN="LEFT"
1298VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001299> the SAX handler block</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001300></TR
1301><TR
1302><TD
1303WIDTH="20%"
1304ALIGN="RIGHT"
1305VALIGN="TOP"
1306><TT
1307CLASS="PARAMETER"
1308><I
1309>userData</I
1310></TT
1311>&nbsp;:</TD
1312><TD
1313WIDTH="80%"
1314ALIGN="LEFT"
1315VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001316> if using SAX, this pointer will be provided on callbacks. </TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001317></TR
1318><TR
1319><TD
1320WIDTH="20%"
1321ALIGN="RIGHT"
1322VALIGN="TOP"
1323><I
1324CLASS="EMPHASIS"
1325>Returns</I
1326> :</TD
1327><TD
1328WIDTH="80%"
1329ALIGN="LEFT"
1330VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001331>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001332></TR
1333></TABLE
1334><P
1335></P
1336></DIV
1337></DIV
1338><HR><DIV
1339CLASS="REFSECT2"
1340><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001341NAME="AEN8139"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001342></A
1343><H3
1344><A
1345NAME="HTMLPARSEDOC"
1346></A
1347>htmlParseDoc ()</H3
1348><TABLE
1349BORDER="0"
1350BGCOLOR="#D6E8FF"
1351WIDTH="100%"
1352CELLPADDING="6"
1353><TR
1354><TD
1355><PRE
1356CLASS="PROGRAMLISTING"
1357><A
1358HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1359>htmlDocPtr</A
1360> htmlParseDoc (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +00001361HREF="gnome-xml-tree.html#XMLCHAR"
1362>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001363> *cur,
1364 const char *encoding);</PRE
1365></TD
1366></TR
1367></TABLE
1368><P
1369>parse an HTML in-memory document and build a tree.</P
1370><P
1371></P
1372><DIV
1373CLASS="INFORMALTABLE"
1374><P
1375></P
1376><TABLE
1377BORDER="0"
1378WIDTH="100%"
1379BGCOLOR="#FFD0D0"
1380CELLSPACING="0"
1381CELLPADDING="4"
1382CLASS="CALSTABLE"
1383><TR
1384><TD
1385WIDTH="20%"
1386ALIGN="RIGHT"
1387VALIGN="TOP"
1388><TT
1389CLASS="PARAMETER"
1390><I
1391>cur</I
1392></TT
1393>&nbsp;:</TD
1394><TD
1395WIDTH="80%"
1396ALIGN="LEFT"
1397VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001398> a pointer to an array of xmlChar</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001399></TR
1400><TR
1401><TD
1402WIDTH="20%"
1403ALIGN="RIGHT"
1404VALIGN="TOP"
1405><TT
1406CLASS="PARAMETER"
1407><I
1408>encoding</I
1409></TT
1410>&nbsp;:</TD
1411><TD
1412WIDTH="80%"
1413ALIGN="LEFT"
1414VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001415> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001416></TR
1417><TR
1418><TD
1419WIDTH="20%"
1420ALIGN="RIGHT"
1421VALIGN="TOP"
1422><I
1423CLASS="EMPHASIS"
1424>Returns</I
1425> :</TD
1426><TD
1427WIDTH="80%"
1428ALIGN="LEFT"
1429VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001430>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001431></TR
1432></TABLE
1433><P
1434></P
1435></DIV
1436></DIV
1437><HR><DIV
1438CLASS="REFSECT2"
1439><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001440NAME="AEN8164"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001441></A
1442><H3
1443><A
1444NAME="HTMLSAXPARSEFILE"
1445></A
1446>htmlSAXParseFile ()</H3
1447><TABLE
1448BORDER="0"
1449BGCOLOR="#D6E8FF"
1450WIDTH="100%"
1451CELLPADDING="6"
1452><TR
1453><TD
1454><PRE
1455CLASS="PROGRAMLISTING"
1456><A
1457HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1458>htmlDocPtr</A
1459> htmlSAXParseFile (const char *filename,
1460 const char *encoding,
1461 <A
1462HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
1463>htmlSAXHandlerPtr</A
1464> sax,
1465 void *userData);</PRE
1466></TD
1467></TR
1468></TABLE
1469><P
1470>parse an HTML file and build a tree. Automatic support for ZLIB/Compress
1471compressed document is provided by default if found at compile-time.
1472It use the given SAX function block to handle the parsing callback.
1473If sax is NULL, fallback to the default DOM tree building routines.</P
1474><P
1475></P
1476><DIV
1477CLASS="INFORMALTABLE"
1478><P
1479></P
1480><TABLE
1481BORDER="0"
1482WIDTH="100%"
1483BGCOLOR="#FFD0D0"
1484CELLSPACING="0"
1485CELLPADDING="4"
1486CLASS="CALSTABLE"
1487><TR
1488><TD
1489WIDTH="20%"
1490ALIGN="RIGHT"
1491VALIGN="TOP"
1492><TT
1493CLASS="PARAMETER"
1494><I
1495>filename</I
1496></TT
1497>&nbsp;:</TD
1498><TD
1499WIDTH="80%"
1500ALIGN="LEFT"
1501VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001502> the filename</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001503></TR
1504><TR
1505><TD
1506WIDTH="20%"
1507ALIGN="RIGHT"
1508VALIGN="TOP"
1509><TT
1510CLASS="PARAMETER"
1511><I
1512>encoding</I
1513></TT
1514>&nbsp;:</TD
1515><TD
1516WIDTH="80%"
1517ALIGN="LEFT"
1518VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001519> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001520></TR
1521><TR
1522><TD
1523WIDTH="20%"
1524ALIGN="RIGHT"
1525VALIGN="TOP"
1526><TT
1527CLASS="PARAMETER"
1528><I
1529>sax</I
1530></TT
1531>&nbsp;:</TD
1532><TD
1533WIDTH="80%"
1534ALIGN="LEFT"
1535VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001536> the SAX handler block</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001537></TR
1538><TR
1539><TD
1540WIDTH="20%"
1541ALIGN="RIGHT"
1542VALIGN="TOP"
1543><TT
1544CLASS="PARAMETER"
1545><I
1546>userData</I
1547></TT
1548>&nbsp;:</TD
1549><TD
1550WIDTH="80%"
1551ALIGN="LEFT"
1552VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001553> if using SAX, this pointer will be provided on callbacks. </TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001554></TR
1555><TR
1556><TD
1557WIDTH="20%"
1558ALIGN="RIGHT"
1559VALIGN="TOP"
1560><I
1561CLASS="EMPHASIS"
1562>Returns</I
1563> :</TD
1564><TD
1565WIDTH="80%"
1566ALIGN="LEFT"
1567VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001568>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001569></TR
1570></TABLE
1571><P
1572></P
1573></DIV
1574></DIV
1575><HR><DIV
1576CLASS="REFSECT2"
1577><A
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001578NAME="AEN8197"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001579></A
1580><H3
1581><A
1582NAME="HTMLPARSEFILE"
1583></A
1584>htmlParseFile ()</H3
1585><TABLE
1586BORDER="0"
1587BGCOLOR="#D6E8FF"
1588WIDTH="100%"
1589CELLPADDING="6"
1590><TR
1591><TD
1592><PRE
1593CLASS="PROGRAMLISTING"
1594><A
1595HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1596>htmlDocPtr</A
1597> htmlParseFile (const char *filename,
1598 const char *encoding);</PRE
1599></TD
1600></TR
1601></TABLE
1602><P
1603>parse an HTML file and build a tree. Automatic support for ZLIB/Compress
1604compressed document is provided by default if found at compile-time.</P
1605><P
1606></P
1607><DIV
1608CLASS="INFORMALTABLE"
1609><P
1610></P
1611><TABLE
1612BORDER="0"
1613WIDTH="100%"
1614BGCOLOR="#FFD0D0"
1615CELLSPACING="0"
1616CELLPADDING="4"
1617CLASS="CALSTABLE"
1618><TR
1619><TD
1620WIDTH="20%"
1621ALIGN="RIGHT"
1622VALIGN="TOP"
1623><TT
1624CLASS="PARAMETER"
1625><I
1626>filename</I
1627></TT
1628>&nbsp;:</TD
1629><TD
1630WIDTH="80%"
1631ALIGN="LEFT"
1632VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001633> the filename</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001634></TR
1635><TR
1636><TD
1637WIDTH="20%"
1638ALIGN="RIGHT"
1639VALIGN="TOP"
1640><TT
1641CLASS="PARAMETER"
1642><I
1643>encoding</I
1644></TT
1645>&nbsp;:</TD
1646><TD
1647WIDTH="80%"
1648ALIGN="LEFT"
1649VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001650> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001651></TR
1652><TR
1653><TD
1654WIDTH="20%"
1655ALIGN="RIGHT"
1656VALIGN="TOP"
1657><I
1658CLASS="EMPHASIS"
1659>Returns</I
1660> :</TD
1661><TD
1662WIDTH="80%"
1663ALIGN="LEFT"
1664VALIGN="TOP"
Daniel Veillardbe849cf1999-12-28 16:43:59 +00001665>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001666></TR
1667></TABLE
1668><P
1669></P
1670></DIV
1671></DIV
1672></DIV
1673><DIV
1674CLASS="NAVFOOTER"
Daniel Veillard00fdf371999-10-08 09:40:39 +00001675><BR
1676CLEAR="all"><BR><TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001677WIDTH="100%"
1678BORDER="0"
1679BGCOLOR="#000000"
1680CELLPADDING="1"
1681CELLSPACING="0"
1682><TR
1683><TD
1684WIDTH="25%"
1685BGCOLOR="#C00000"
1686ALIGN="left"
1687><A
Daniel Veillard6bd26dc1999-09-03 14:28:40 +00001688HREF="gnome-xml-xml-error.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001689><FONT
1690COLOR="#FFFFFF"
1691SIZE="3"
1692><B
1693>&#60;&#60;&#60; Previous Page</B
1694></FONT
1695></A
1696></TD
1697><TD
1698WIDTH="25%"
1699BGCOLOR="#0000C0"
1700ALIGN="center"
1701><FONT
1702COLOR="#FFFFFF"
1703SIZE="3"
1704><B
1705><A
1706HREF="book1.html"
1707><FONT
1708COLOR="#FFFFFF"
1709SIZE="3"
1710><B
1711>Home</B
1712></FONT
1713></A
1714></B
1715></FONT
1716></TD
1717><TD
1718WIDTH="25%"
1719BGCOLOR="#00C000"
1720ALIGN="center"
1721><FONT
1722COLOR="#FFFFFF"
1723SIZE="3"
1724><B
1725><A
Daniel Veillard35008381999-10-25 13:15:52 +00001726HREF="libxml-lib.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001727><FONT
1728COLOR="#FFFFFF"
1729SIZE="3"
1730><B
1731>Up</B
1732></FONT
1733></A
1734></B
1735></FONT
1736></TD
1737><TD
1738WIDTH="25%"
1739BGCOLOR="#C00000"
1740ALIGN="right"
1741><A
1742HREF="gnome-xml-htmltree.html"
1743><FONT
1744COLOR="#FFFFFF"
1745SIZE="3"
1746><B
1747>Next Page &#62;&#62;&#62;</B
1748></FONT
1749></A
1750></TD
1751></TR
1752><TR
1753><TD
1754COLSPAN="2"
1755ALIGN="left"
1756><FONT
1757COLOR="#FFFFFF"
1758SIZE="3"
1759><B
Daniel Veillard6bd26dc1999-09-03 14:28:40 +00001760>xml-error</B
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001761></FONT
1762></TD
1763><TD
1764COLSPAN="2"
1765ALIGN="right"
1766><FONT
1767COLOR="#FFFFFF"
1768SIZE="3"
1769><B
1770>HTMLtree</B
1771></FONT
1772></TD
1773></TR
1774></TABLE
1775></DIV
1776></BODY
1777></HTML
1778>