blob: bd34e0d361ce66d37ff8b34dc807f0bd28b920a3 [file] [log] [blame]
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001<HTML
2><HEAD
3><TITLE
4>HTMLparser</TITLE
5><META
6NAME="GENERATOR"
Daniel Veillard503b8932001-01-05 06:36:31 +00007CONTENT="Modular DocBook HTML Stylesheet Version 1.44"><LINK
Daniel Veillard1566d3a1999-07-15 14:24:29 +00008REL="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 Veillard503b8932001-01-05 06:36:31 +000015TITLE="uri"
16HREF="gnome-xml-uri.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"
Daniel Veillard503b8932001-01-05 06:36:31 +000023LINK="#0000FF"
24VLINK="#840084"
25ALINK="#0000FF"
Daniel Veillard1566d3a1999-07-15 14:24:29 +000026><DIV
27CLASS="NAVHEADER"
28><TABLE
29WIDTH="100%"
30BORDER="0"
31BGCOLOR="#000000"
32CELLPADDING="1"
33CELLSPACING="0"
34><TR
35><TH
36COLSPAN="4"
37ALIGN="center"
38><FONT
39COLOR="#FFFFFF"
40SIZE="5"
41>Gnome XML Library Reference Manual</FONT
42></TH
43></TR
44><TR
45><TD
46WIDTH="25%"
47BGCOLOR="#C00000"
48ALIGN="left"
49><A
Daniel Veillard503b8932001-01-05 06:36:31 +000050HREF="gnome-xml-uri.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +000051><FONT
52COLOR="#FFFFFF"
53SIZE="3"
54><B
55>&#60;&#60;&#60; Previous Page</B
56></FONT
57></A
58></TD
59><TD
60WIDTH="25%"
61BGCOLOR="#0000C0"
62ALIGN="center"
63><FONT
64COLOR="#FFFFFF"
65SIZE="3"
66><B
67><A
68HREF="book1.html"
69><FONT
70COLOR="#FFFFFF"
71SIZE="3"
72><B
73>Home</B
74></FONT
75></A
76></B
77></FONT
78></TD
79><TD
80WIDTH="25%"
81BGCOLOR="#00C000"
82ALIGN="center"
83><FONT
84COLOR="#FFFFFF"
85SIZE="3"
86><B
87><A
Daniel Veillard35008381999-10-25 13:15:52 +000088HREF="libxml-lib.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +000089><FONT
90COLOR="#FFFFFF"
91SIZE="3"
92><B
93>Up</B
94></FONT
95></A
96></B
97></FONT
98></TD
99><TD
100WIDTH="25%"
101BGCOLOR="#C00000"
102ALIGN="right"
103><A
104HREF="gnome-xml-htmltree.html"
105><FONT
106COLOR="#FFFFFF"
107SIZE="3"
108><B
109>Next Page &#62;&#62;&#62;</B
110></FONT
111></A
112></TD
113></TR
114></TABLE
115></DIV
116><H1
Daniel Veillard503b8932001-01-05 06:36:31 +0000117><A
118NAME="GNOME-XML-HTMLPARSER"
119>HTMLparser</A
120></H1
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000121><DIV
122CLASS="REFNAMEDIV"
123><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000124NAME="AEN9548"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000125></A
126><H2
127>Name</H2
Daniel Veillard503b8932001-01-05 06:36:31 +0000128>HTMLparser&nbsp;--&nbsp;</DIV
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000129><DIV
130CLASS="REFSYNOPSISDIV"
131><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000132NAME="AEN9551"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000133></A
134><H2
135>Synopsis</H2
136><TABLE
137BORDER="0"
138BGCOLOR="#D6E8FF"
139WIDTH="100%"
140CELLPADDING="6"
141><TR
142><TD
143><PRE
144CLASS="SYNOPSIS"
145>&#13;
146
147typedef <A
148HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXT"
149>htmlParserCtxt</A
150>;
151typedef <A
152HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
153>htmlParserCtxtPtr</A
154>;
155typedef <A
156HREF="gnome-xml-htmlparser.html#HTMLPARSERNODEINFO"
157>htmlParserNodeInfo</A
158>;
159typedef <A
160HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLER"
161>htmlSAXHandler</A
162>;
163typedef <A
164HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
165>htmlSAXHandlerPtr</A
166>;
167typedef <A
168HREF="gnome-xml-htmlparser.html#HTMLPARSERINPUT"
169>htmlParserInput</A
170>;
171typedef <A
172HREF="gnome-xml-htmlparser.html#HTMLPARSERINPUTPTR"
173>htmlParserInputPtr</A
174>;
175typedef <A
176HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
177>htmlDocPtr</A
178>;
179typedef <A
180HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
181>htmlNodePtr</A
182>;
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000183struct <A
184HREF="gnome-xml-htmlparser.html#HTMLELEMDESC"
185>htmlElemDesc</A
186>;
187typedef <A
188HREF="gnome-xml-htmlparser.html#HTMLELEMDESCPTR"
189>htmlElemDescPtr</A
190>;
191struct <A
192HREF="gnome-xml-htmlparser.html#HTMLENTITYDESC"
193>htmlEntityDesc</A
194>;
195typedef <A
196HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
197>htmlEntityDescPtr</A
198>;
199<A
200HREF="gnome-xml-htmlparser.html#HTMLELEMDESCPTR"
201>htmlElemDescPtr</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000202> <A
203HREF="gnome-xml-htmlparser.html#HTMLTAGLOOKUP"
204>htmlTagLookup</A
205> (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000206HREF="gnome-xml-tree.html#XMLCHAR"
207>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000208> *tag);
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000209<A
210HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
211>htmlEntityDescPtr</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000212> <A
213HREF="gnome-xml-htmlparser.html#HTMLENTITYLOOKUP"
214>htmlEntityLookup</A
215> (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000216HREF="gnome-xml-tree.html#XMLCHAR"
217>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000218> *name);
Daniel Veillard3bff2b02000-10-01 20:33:47 +0000219<A
220HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
221>htmlEntityDescPtr</A
222> <A
223HREF="gnome-xml-htmlparser.html#HTMLENTITYVALUELOOKUP"
224>htmlEntityValueLookup</A
225> (int value);
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000226int <A
227HREF="gnome-xml-htmlparser.html#HTMLISAUTOCLOSED"
228>htmlIsAutoClosed</A
229> (<A
230HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
231>htmlDocPtr</A
232> doc,
233 <A
234HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
235>htmlNodePtr</A
236> elem);
237int <A
238HREF="gnome-xml-htmlparser.html#HTMLAUTOCLOSETAG"
239>htmlAutoCloseTag</A
240> (<A
241HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
242>htmlDocPtr</A
243> doc,
244 const <A
245HREF="gnome-xml-tree.html#XMLCHAR"
246>xmlChar</A
247> *name,
248 <A
249HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
250>htmlNodePtr</A
251> elem);
252<A
253HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
254>htmlEntityDescPtr</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000255> <A
256HREF="gnome-xml-htmlparser.html#HTMLPARSEENTITYREF"
257>htmlParseEntityRef</A
258> (<A
259HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
260>htmlParserCtxtPtr</A
261> ctxt,
262 <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000263HREF="gnome-xml-tree.html#XMLCHAR"
264>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000265> **str);
266int <A
267HREF="gnome-xml-htmlparser.html#HTMLPARSECHARREF"
268>htmlParseCharRef</A
269> (<A
270HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
271>htmlParserCtxtPtr</A
272> ctxt);
273void <A
274HREF="gnome-xml-htmlparser.html#HTMLPARSEELEMENT"
275>htmlParseElement</A
276> (<A
277HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
278>htmlParserCtxtPtr</A
279> ctxt);
280<A
281HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
282>htmlDocPtr</A
283> <A
284HREF="gnome-xml-htmlparser.html#HTMLSAXPARSEDOC"
285>htmlSAXParseDoc</A
286> (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000287HREF="gnome-xml-tree.html#XMLCHAR"
288>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000289> *cur,
290 const char *encoding,
291 <A
292HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
293>htmlSAXHandlerPtr</A
294> sax,
295 void *userData);
296<A
297HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
298>htmlDocPtr</A
299> <A
300HREF="gnome-xml-htmlparser.html#HTMLPARSEDOC"
301>htmlParseDoc</A
302> (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000303HREF="gnome-xml-tree.html#XMLCHAR"
304>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000305> *cur,
306 const char *encoding);
307<A
308HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
309>htmlDocPtr</A
310> <A
311HREF="gnome-xml-htmlparser.html#HTMLSAXPARSEFILE"
312>htmlSAXParseFile</A
313> (const char *filename,
314 const char *encoding,
315 <A
316HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
317>htmlSAXHandlerPtr</A
318> sax,
319 void *userData);
320<A
321HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
322>htmlDocPtr</A
323> <A
324HREF="gnome-xml-htmlparser.html#HTMLPARSEFILE"
325>htmlParseFile</A
326> (const char *filename,
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000327 const char *encoding);
Daniel Veillarde46e20d2000-07-14 15:02:46 +0000328int <A
329HREF="gnome-xml-htmlparser.html#UTF8TOHTML"
330>UTF8ToHtml</A
331> (unsigned char *out,
332 int *outlen,
333 unsigned char *in,
334 int *inlen);
Daniel Veillard3bff2b02000-10-01 20:33:47 +0000335int <A
336HREF="gnome-xml-htmlparser.html#HTMLENCODEENTITIES"
337>htmlEncodeEntities</A
338> (unsigned char *out,
339 int *outlen,
340 unsigned char *in,
341 int *inlen,
342 int quoteChar);
Daniel Veillard29a11cc2000-10-25 13:32:39 +0000343int <A
344HREF="gnome-xml-htmlparser.html#HTMLISSCRIPTATTRIBUTE"
345>htmlIsScriptAttribute</A
346> (const <A
347HREF="gnome-xml-tree.html#XMLCHAR"
348>xmlChar</A
349> *name);
Daniel Veillard503b8932001-01-05 06:36:31 +0000350int <A
351HREF="gnome-xml-htmlparser.html#HTMLHANDLEOMITTEDELEM"
352>htmlHandleOmittedElem</A
353> (int val);
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000354void <A
355HREF="gnome-xml-htmlparser.html#HTMLFREEPARSERCTXT"
356>htmlFreeParserCtxt</A
357> (<A
358HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
359>htmlParserCtxtPtr</A
360> ctxt);
361<A
362HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
363>htmlParserCtxtPtr</A
364> <A
365HREF="gnome-xml-htmlparser.html#HTMLCREATEPUSHPARSERCTXT"
366>htmlCreatePushParserCtxt</A
367> (<A
368HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
369>htmlSAXHandlerPtr</A
370> sax,
371 void *user_data,
372 const char *chunk,
373 int size,
374 const char *filename,
375 <A
376HREF="gnome-xml-encoding.html#XMLCHARENCODING"
377>xmlCharEncoding</A
378> enc);
379int <A
380HREF="gnome-xml-htmlparser.html#HTMLPARSECHUNK"
381>htmlParseChunk</A
382> (<A
383HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
384>htmlParserCtxtPtr</A
385> ctxt,
386 const char *chunk,
387 int size,
388 int terminate);</PRE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000389></TD
390></TR
391></TABLE
392></DIV
393><DIV
394CLASS="REFSECT1"
395><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000396NAME="AEN9615"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000397></A
398><H2
399>Description</H2
400><P
401></P
402></DIV
403><DIV
404CLASS="REFSECT1"
405><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000406NAME="AEN9618"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000407></A
408><H2
409>Details</H2
410><DIV
411CLASS="REFSECT2"
412><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000413NAME="AEN9620"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000414></A
415><H3
416><A
417NAME="HTMLPARSERCTXT"
418></A
419>htmlParserCtxt</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000420><TABLE
421BORDER="0"
422BGCOLOR="#D6E8FF"
423WIDTH="100%"
424CELLPADDING="6"
425><TR
426><TD
427><PRE
428CLASS="PROGRAMLISTING"
429>typedef xmlParserCtxt htmlParserCtxt;</PRE
430></TD
431></TR
432></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000433><P
434></P
435></DIV
436><HR><DIV
437CLASS="REFSECT2"
438><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000439NAME="AEN9625"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000440></A
441><H3
442><A
443NAME="HTMLPARSERCTXTPTR"
444></A
445>htmlParserCtxtPtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000446><TABLE
447BORDER="0"
448BGCOLOR="#D6E8FF"
449WIDTH="100%"
450CELLPADDING="6"
451><TR
452><TD
453><PRE
454CLASS="PROGRAMLISTING"
455>typedef xmlParserCtxtPtr htmlParserCtxtPtr;</PRE
456></TD
457></TR
458></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000459><P
460></P
461></DIV
462><HR><DIV
463CLASS="REFSECT2"
464><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000465NAME="AEN9630"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000466></A
467><H3
468><A
469NAME="HTMLPARSERNODEINFO"
470></A
471>htmlParserNodeInfo</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000472><TABLE
473BORDER="0"
474BGCOLOR="#D6E8FF"
475WIDTH="100%"
476CELLPADDING="6"
477><TR
478><TD
479><PRE
480CLASS="PROGRAMLISTING"
481>typedef xmlParserNodeInfo htmlParserNodeInfo;</PRE
482></TD
483></TR
484></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000485><P
486></P
487></DIV
488><HR><DIV
489CLASS="REFSECT2"
490><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000491NAME="AEN9635"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000492></A
493><H3
494><A
495NAME="HTMLSAXHANDLER"
496></A
497>htmlSAXHandler</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000498><TABLE
499BORDER="0"
500BGCOLOR="#D6E8FF"
501WIDTH="100%"
502CELLPADDING="6"
503><TR
504><TD
505><PRE
506CLASS="PROGRAMLISTING"
507>typedef xmlSAXHandler htmlSAXHandler;</PRE
508></TD
509></TR
510></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000511><P
512></P
513></DIV
514><HR><DIV
515CLASS="REFSECT2"
516><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000517NAME="AEN9640"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000518></A
519><H3
520><A
521NAME="HTMLSAXHANDLERPTR"
522></A
523>htmlSAXHandlerPtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000524><TABLE
525BORDER="0"
526BGCOLOR="#D6E8FF"
527WIDTH="100%"
528CELLPADDING="6"
529><TR
530><TD
531><PRE
532CLASS="PROGRAMLISTING"
533>typedef xmlSAXHandlerPtr htmlSAXHandlerPtr;</PRE
534></TD
535></TR
536></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000537><P
538></P
539></DIV
540><HR><DIV
541CLASS="REFSECT2"
542><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000543NAME="AEN9645"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000544></A
545><H3
546><A
547NAME="HTMLPARSERINPUT"
548></A
549>htmlParserInput</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000550><TABLE
551BORDER="0"
552BGCOLOR="#D6E8FF"
553WIDTH="100%"
554CELLPADDING="6"
555><TR
556><TD
557><PRE
558CLASS="PROGRAMLISTING"
559>typedef xmlParserInput htmlParserInput;</PRE
560></TD
561></TR
562></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000563><P
564></P
565></DIV
566><HR><DIV
567CLASS="REFSECT2"
568><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000569NAME="AEN9650"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000570></A
571><H3
572><A
573NAME="HTMLPARSERINPUTPTR"
574></A
575>htmlParserInputPtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000576><TABLE
577BORDER="0"
578BGCOLOR="#D6E8FF"
579WIDTH="100%"
580CELLPADDING="6"
581><TR
582><TD
583><PRE
584CLASS="PROGRAMLISTING"
585>typedef xmlParserInputPtr htmlParserInputPtr;</PRE
586></TD
587></TR
588></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000589><P
590></P
591></DIV
592><HR><DIV
593CLASS="REFSECT2"
594><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000595NAME="AEN9655"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000596></A
597><H3
598><A
599NAME="HTMLDOCPTR"
600></A
601>htmlDocPtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000602><TABLE
603BORDER="0"
604BGCOLOR="#D6E8FF"
605WIDTH="100%"
606CELLPADDING="6"
607><TR
608><TD
609><PRE
610CLASS="PROGRAMLISTING"
611>typedef xmlDocPtr htmlDocPtr;</PRE
612></TD
613></TR
614></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000615><P
616></P
617></DIV
618><HR><DIV
619CLASS="REFSECT2"
620><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000621NAME="AEN9660"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000622></A
623><H3
624><A
625NAME="HTMLNODEPTR"
626></A
627>htmlNodePtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000628><TABLE
629BORDER="0"
630BGCOLOR="#D6E8FF"
631WIDTH="100%"
632CELLPADDING="6"
633><TR
634><TD
635><PRE
636CLASS="PROGRAMLISTING"
637>typedef xmlNodePtr htmlNodePtr;</PRE
638></TD
639></TR
640></TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000641><P
642></P
643></DIV
644><HR><DIV
645CLASS="REFSECT2"
646><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000647NAME="AEN9665"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000648></A
649><H3
650><A
651NAME="HTMLELEMDESC"
652></A
653>struct htmlElemDesc</H3
654><TABLE
655BORDER="0"
656BGCOLOR="#D6E8FF"
657WIDTH="100%"
658CELLPADDING="6"
659><TR
660><TD
661><PRE
662CLASS="PROGRAMLISTING"
663>struct htmlElemDesc {
664 const char *name; /* The tag name */
665 int startTag; /* Whether the start tag can be implied */
666 int endTag; /* Whether the end tag can be implied */
667 int empty; /* Is this an empty element ? */
668 int depr; /* Is this a deprecated element ? */
669 int dtd; /* 1: only in Loose DTD, 2: only Frameset one */
670 const char *desc; /* the description */
671};</PRE
672></TD
673></TR
674></TABLE
675><P
676></P
677></DIV
678><HR><DIV
679CLASS="REFSECT2"
680><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000681NAME="AEN9670"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000682></A
683><H3
684><A
685NAME="HTMLELEMDESCPTR"
686></A
687>htmlElemDescPtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000688><TABLE
689BORDER="0"
690BGCOLOR="#D6E8FF"
691WIDTH="100%"
692CELLPADDING="6"
693><TR
694><TD
695><PRE
696CLASS="PROGRAMLISTING"
697>typedef htmlElemDesc *htmlElemDescPtr;</PRE
698></TD
699></TR
700></TABLE
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000701><P
702></P
703></DIV
704><HR><DIV
705CLASS="REFSECT2"
706><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000707NAME="AEN9675"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000708></A
709><H3
710><A
711NAME="HTMLENTITYDESC"
712></A
713>struct htmlEntityDesc</H3
714><TABLE
715BORDER="0"
716BGCOLOR="#D6E8FF"
717WIDTH="100%"
718CELLPADDING="6"
719><TR
720><TD
721><PRE
722CLASS="PROGRAMLISTING"
723>struct htmlEntityDesc {
724 int value; /* the UNICODE value for the character */
725 const char *name; /* The entity name */
726 const char *desc; /* the description */
727};</PRE
728></TD
729></TR
730></TABLE
731><P
732></P
733></DIV
734><HR><DIV
735CLASS="REFSECT2"
736><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000737NAME="AEN9680"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000738></A
739><H3
740><A
741NAME="HTMLENTITYDESCPTR"
742></A
743>htmlEntityDescPtr</H3
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000744><TABLE
745BORDER="0"
746BGCOLOR="#D6E8FF"
747WIDTH="100%"
748CELLPADDING="6"
749><TR
750><TD
751><PRE
752CLASS="PROGRAMLISTING"
753>typedef htmlEntityDesc *htmlEntityDescPtr;</PRE
754></TD
755></TR
756></TABLE
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000757><P
758></P
759></DIV
760><HR><DIV
761CLASS="REFSECT2"
762><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000763NAME="AEN9685"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000764></A
765><H3
766><A
767NAME="HTMLTAGLOOKUP"
768></A
769>htmlTagLookup ()</H3
770><TABLE
771BORDER="0"
772BGCOLOR="#D6E8FF"
773WIDTH="100%"
774CELLPADDING="6"
775><TR
776><TD
777><PRE
778CLASS="PROGRAMLISTING"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000779><A
780HREF="gnome-xml-htmlparser.html#HTMLELEMDESCPTR"
781>htmlElemDescPtr</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000782> htmlTagLookup (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000783HREF="gnome-xml-tree.html#XMLCHAR"
784>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000785> *tag);</PRE
786></TD
787></TR
788></TABLE
789><P
790>Lookup the HTML tag in the ElementTable</P
791><P
792></P
793><DIV
794CLASS="INFORMALTABLE"
795><P
796></P
797><TABLE
798BORDER="0"
799WIDTH="100%"
800BGCOLOR="#FFD0D0"
801CELLSPACING="0"
802CELLPADDING="4"
803CLASS="CALSTABLE"
804><TR
805><TD
806WIDTH="20%"
807ALIGN="RIGHT"
808VALIGN="TOP"
809><TT
810CLASS="PARAMETER"
811><I
812>tag</I
813></TT
814>&nbsp;:</TD
815><TD
816WIDTH="80%"
817ALIGN="LEFT"
818VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000819> The tag name in lowercase</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000820></TR
821><TR
822><TD
823WIDTH="20%"
824ALIGN="RIGHT"
825VALIGN="TOP"
826><I
827CLASS="EMPHASIS"
828>Returns</I
829> :</TD
830><TD
831WIDTH="80%"
832ALIGN="LEFT"
833VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000834>the related htmlElemDescPtr or NULL if not found.</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000835></TR
836></TABLE
837><P
838></P
839></DIV
840></DIV
841><HR><DIV
842CLASS="REFSECT2"
843><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000844NAME="AEN9706"
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000845></A
846><H3
847><A
848NAME="HTMLENTITYLOOKUP"
849></A
850>htmlEntityLookup ()</H3
851><TABLE
852BORDER="0"
853BGCOLOR="#D6E8FF"
854WIDTH="100%"
855CELLPADDING="6"
856><TR
857><TD
858><PRE
859CLASS="PROGRAMLISTING"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +0000860><A
861HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
862>htmlEntityDescPtr</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000863> htmlEntityLookup (const <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +0000864HREF="gnome-xml-tree.html#XMLCHAR"
865>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000866> *name);</PRE
867></TD
868></TR
869></TABLE
870><P
871>Lookup the given entity in EntitiesTable</P
872><P
873>TODO: the linear scan is really ugly, an hash table is really needed.</P
874><P
875></P
876><DIV
877CLASS="INFORMALTABLE"
878><P
879></P
880><TABLE
881BORDER="0"
882WIDTH="100%"
883BGCOLOR="#FFD0D0"
884CELLSPACING="0"
885CELLPADDING="4"
886CLASS="CALSTABLE"
887><TR
888><TD
889WIDTH="20%"
890ALIGN="RIGHT"
891VALIGN="TOP"
892><TT
893CLASS="PARAMETER"
894><I
895>name</I
896></TT
897>&nbsp;:</TD
898><TD
899WIDTH="80%"
900ALIGN="LEFT"
901VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000902> the entity name</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000903></TR
904><TR
905><TD
906WIDTH="20%"
907ALIGN="RIGHT"
908VALIGN="TOP"
909><I
910CLASS="EMPHASIS"
911>Returns</I
912> :</TD
913><TD
914WIDTH="80%"
915ALIGN="LEFT"
916VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000917>the associated htmlEntityDescPtr if found, NULL otherwise.</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +0000918></TR
919></TABLE
920><P
921></P
922></DIV
923></DIV
924><HR><DIV
925CLASS="REFSECT2"
926><A
Daniel Veillard503b8932001-01-05 06:36:31 +0000927NAME="AEN9728"
Daniel Veillard3bff2b02000-10-01 20:33:47 +0000928></A
929><H3
930><A
931NAME="HTMLENTITYVALUELOOKUP"
932></A
933>htmlEntityValueLookup ()</H3
934><TABLE
935BORDER="0"
936BGCOLOR="#D6E8FF"
937WIDTH="100%"
938CELLPADDING="6"
939><TR
940><TD
941><PRE
942CLASS="PROGRAMLISTING"
943><A
944HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
945>htmlEntityDescPtr</A
946> htmlEntityValueLookup (int value);</PRE
947></TD
948></TR
949></TABLE
950><P
951>Lookup the given entity in EntitiesTable</P
952><P
953>TODO: the linear scan is really ugly, an hash table is really needed.</P
954><P
955></P
956><DIV
957CLASS="INFORMALTABLE"
958><P
959></P
960><TABLE
961BORDER="0"
962WIDTH="100%"
963BGCOLOR="#FFD0D0"
964CELLSPACING="0"
965CELLPADDING="4"
966CLASS="CALSTABLE"
967><TR
968><TD
969WIDTH="20%"
970ALIGN="RIGHT"
971VALIGN="TOP"
972><TT
973CLASS="PARAMETER"
974><I
975>value</I
976></TT
977>&nbsp;:</TD
978><TD
979WIDTH="80%"
980ALIGN="LEFT"
981VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000982> the entity's unicode value</TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +0000983></TR
984><TR
985><TD
986WIDTH="20%"
987ALIGN="RIGHT"
988VALIGN="TOP"
989><I
990CLASS="EMPHASIS"
991>Returns</I
992> :</TD
993><TD
994WIDTH="80%"
995ALIGN="LEFT"
996VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +0000997>the associated htmlEntityDescPtr if found, NULL otherwise.</TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +0000998></TR
999></TABLE
1000><P
1001></P
1002></DIV
1003></DIV
1004><HR><DIV
1005CLASS="REFSECT2"
1006><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001007NAME="AEN9749"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001008></A
1009><H3
1010><A
1011NAME="HTMLISAUTOCLOSED"
1012></A
1013>htmlIsAutoClosed ()</H3
1014><TABLE
1015BORDER="0"
1016BGCOLOR="#D6E8FF"
1017WIDTH="100%"
1018CELLPADDING="6"
1019><TR
1020><TD
1021><PRE
1022CLASS="PROGRAMLISTING"
1023>int htmlIsAutoClosed (<A
1024HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1025>htmlDocPtr</A
1026> doc,
1027 <A
1028HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
1029>htmlNodePtr</A
1030> elem);</PRE
1031></TD
1032></TR
1033></TABLE
1034><P
1035>The HTmL DtD allows a tag to implicitely close other tags.
1036The list is kept in htmlStartClose array. This function checks
1037if a tag is autoclosed by one of it's child</P
1038><P
1039></P
1040><DIV
1041CLASS="INFORMALTABLE"
1042><P
1043></P
1044><TABLE
1045BORDER="0"
1046WIDTH="100%"
1047BGCOLOR="#FFD0D0"
1048CELLSPACING="0"
1049CELLPADDING="4"
1050CLASS="CALSTABLE"
1051><TR
1052><TD
1053WIDTH="20%"
1054ALIGN="RIGHT"
1055VALIGN="TOP"
1056><TT
1057CLASS="PARAMETER"
1058><I
1059>doc</I
1060></TT
1061>&nbsp;:</TD
1062><TD
1063WIDTH="80%"
1064ALIGN="LEFT"
1065VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001066> the HTML document</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001067></TR
1068><TR
1069><TD
1070WIDTH="20%"
1071ALIGN="RIGHT"
1072VALIGN="TOP"
1073><TT
1074CLASS="PARAMETER"
1075><I
1076>elem</I
1077></TT
1078>&nbsp;:</TD
1079><TD
1080WIDTH="80%"
1081ALIGN="LEFT"
1082VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001083> the HTML element</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001084></TR
1085><TR
1086><TD
1087WIDTH="20%"
1088ALIGN="RIGHT"
1089VALIGN="TOP"
1090><I
1091CLASS="EMPHASIS"
1092>Returns</I
1093> :</TD
1094><TD
1095WIDTH="80%"
1096ALIGN="LEFT"
1097VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001098>1 if autoclosed, 0 otherwise</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001099></TR
1100></TABLE
1101><P
1102></P
1103></DIV
1104></DIV
1105><HR><DIV
1106CLASS="REFSECT2"
1107><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001108NAME="AEN9774"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001109></A
1110><H3
1111><A
1112NAME="HTMLAUTOCLOSETAG"
1113></A
1114>htmlAutoCloseTag ()</H3
1115><TABLE
1116BORDER="0"
1117BGCOLOR="#D6E8FF"
1118WIDTH="100%"
1119CELLPADDING="6"
1120><TR
1121><TD
1122><PRE
1123CLASS="PROGRAMLISTING"
1124>int htmlAutoCloseTag (<A
1125HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1126>htmlDocPtr</A
1127> doc,
1128 const <A
1129HREF="gnome-xml-tree.html#XMLCHAR"
1130>xmlChar</A
1131> *name,
1132 <A
1133HREF="gnome-xml-htmlparser.html#HTMLNODEPTR"
1134>htmlNodePtr</A
1135> elem);</PRE
1136></TD
1137></TR
1138></TABLE
1139><P
1140>The HTmL DtD allows a tag to implicitely close other tags.
1141The list is kept in htmlStartClose array. This function checks
1142if the element or one of it's children would autoclose the
1143given tag.</P
1144><P
1145></P
1146><DIV
1147CLASS="INFORMALTABLE"
1148><P
1149></P
1150><TABLE
1151BORDER="0"
1152WIDTH="100%"
1153BGCOLOR="#FFD0D0"
1154CELLSPACING="0"
1155CELLPADDING="4"
1156CLASS="CALSTABLE"
1157><TR
1158><TD
1159WIDTH="20%"
1160ALIGN="RIGHT"
1161VALIGN="TOP"
1162><TT
1163CLASS="PARAMETER"
1164><I
1165>doc</I
1166></TT
1167>&nbsp;:</TD
1168><TD
1169WIDTH="80%"
1170ALIGN="LEFT"
1171VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001172> the HTML document</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001173></TR
1174><TR
1175><TD
1176WIDTH="20%"
1177ALIGN="RIGHT"
1178VALIGN="TOP"
1179><TT
1180CLASS="PARAMETER"
1181><I
1182>name</I
1183></TT
1184>&nbsp;:</TD
1185><TD
1186WIDTH="80%"
1187ALIGN="LEFT"
1188VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001189> The tag name</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001190></TR
1191><TR
1192><TD
1193WIDTH="20%"
1194ALIGN="RIGHT"
1195VALIGN="TOP"
1196><TT
1197CLASS="PARAMETER"
1198><I
1199>elem</I
1200></TT
1201>&nbsp;:</TD
1202><TD
1203WIDTH="80%"
1204ALIGN="LEFT"
1205VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001206> the HTML element</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001207></TR
1208><TR
1209><TD
1210WIDTH="20%"
1211ALIGN="RIGHT"
1212VALIGN="TOP"
1213><I
1214CLASS="EMPHASIS"
1215>Returns</I
1216> :</TD
1217><TD
1218WIDTH="80%"
1219ALIGN="LEFT"
1220VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001221>1 if autoclose, 0 otherwise</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001222></TR
1223></TABLE
1224><P
1225></P
1226></DIV
1227></DIV
1228><HR><DIV
1229CLASS="REFSECT2"
1230><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001231NAME="AEN9804"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001232></A
1233><H3
1234><A
1235NAME="HTMLPARSEENTITYREF"
1236></A
1237>htmlParseEntityRef ()</H3
1238><TABLE
1239BORDER="0"
1240BGCOLOR="#D6E8FF"
1241WIDTH="100%"
1242CELLPADDING="6"
1243><TR
1244><TD
1245><PRE
1246CLASS="PROGRAMLISTING"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001247><A
1248HREF="gnome-xml-htmlparser.html#HTMLENTITYDESCPTR"
1249>htmlEntityDescPtr</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001250> htmlParseEntityRef (<A
1251HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
1252>htmlParserCtxtPtr</A
1253> ctxt,
1254 <A
Daniel Veillarddd6b3671999-09-23 22:19:22 +00001255HREF="gnome-xml-tree.html#XMLCHAR"
1256>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001257> **str);</PRE
1258></TD
1259></TR
1260></TABLE
1261><P
1262>parse an HTML ENTITY references</P
1263><P
1264>[68] EntityRef ::= '&amp;' Name ';'</P
1265><P
1266></P
1267><DIV
1268CLASS="INFORMALTABLE"
1269><P
1270></P
1271><TABLE
1272BORDER="0"
1273WIDTH="100%"
1274BGCOLOR="#FFD0D0"
1275CELLSPACING="0"
1276CELLPADDING="4"
1277CLASS="CALSTABLE"
1278><TR
1279><TD
1280WIDTH="20%"
1281ALIGN="RIGHT"
1282VALIGN="TOP"
1283><TT
1284CLASS="PARAMETER"
1285><I
1286>ctxt</I
1287></TT
1288>&nbsp;:</TD
1289><TD
1290WIDTH="80%"
1291ALIGN="LEFT"
1292VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001293> an HTML parser context</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001294></TR
1295><TR
1296><TD
1297WIDTH="20%"
1298ALIGN="RIGHT"
1299VALIGN="TOP"
1300><TT
1301CLASS="PARAMETER"
1302><I
1303>str</I
1304></TT
1305>&nbsp;:</TD
1306><TD
1307WIDTH="80%"
1308ALIGN="LEFT"
1309VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001310> location to store the entity name</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001311></TR
1312><TR
1313><TD
1314WIDTH="20%"
1315ALIGN="RIGHT"
1316VALIGN="TOP"
1317><I
1318CLASS="EMPHASIS"
1319>Returns</I
1320> :</TD
1321><TD
1322WIDTH="80%"
1323ALIGN="LEFT"
1324VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001325>the associated htmlEntityDescPtr if found, or NULL otherwise,
1326if non-NULL *str will have to be freed by the caller.</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001327></TR
1328></TABLE
1329><P
1330></P
1331></DIV
1332></DIV
1333><HR><DIV
1334CLASS="REFSECT2"
1335><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001336NAME="AEN9831"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001337></A
1338><H3
1339><A
1340NAME="HTMLPARSECHARREF"
1341></A
1342>htmlParseCharRef ()</H3
1343><TABLE
1344BORDER="0"
1345BGCOLOR="#D6E8FF"
1346WIDTH="100%"
1347CELLPADDING="6"
1348><TR
1349><TD
1350><PRE
1351CLASS="PROGRAMLISTING"
1352>int htmlParseCharRef (<A
1353HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
1354>htmlParserCtxtPtr</A
1355> ctxt);</PRE
1356></TD
1357></TR
1358></TABLE
1359><P
1360>parse Reference declarations</P
1361><P
1362>[66] CharRef ::= '&amp;#' [0-9]+ ';' |
1363'&amp;<GTKDOCLINK
1364HREF="X"
1365>x</GTKDOCLINK
1366>' [0-9a-fA-F]+ ';'</P
1367><P
1368></P
1369><DIV
1370CLASS="INFORMALTABLE"
1371><P
1372></P
1373><TABLE
1374BORDER="0"
1375WIDTH="100%"
1376BGCOLOR="#FFD0D0"
1377CELLSPACING="0"
1378CELLPADDING="4"
1379CLASS="CALSTABLE"
1380><TR
1381><TD
1382WIDTH="20%"
1383ALIGN="RIGHT"
1384VALIGN="TOP"
1385><TT
1386CLASS="PARAMETER"
1387><I
1388>ctxt</I
1389></TT
1390>&nbsp;:</TD
1391><TD
1392WIDTH="80%"
1393ALIGN="LEFT"
1394VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001395> an HTML parser context</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001396></TR
1397><TR
1398><TD
1399WIDTH="20%"
1400ALIGN="RIGHT"
1401VALIGN="TOP"
1402><I
1403CLASS="EMPHASIS"
1404>Returns</I
1405> :</TD
1406><TD
1407WIDTH="80%"
1408ALIGN="LEFT"
1409VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001410>the value parsed (as an int)</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001411></TR
1412></TABLE
1413><P
1414></P
1415></DIV
1416></DIV
1417><HR><DIV
1418CLASS="REFSECT2"
1419><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001420NAME="AEN9853"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001421></A
1422><H3
1423><A
1424NAME="HTMLPARSEELEMENT"
1425></A
1426>htmlParseElement ()</H3
1427><TABLE
1428BORDER="0"
1429BGCOLOR="#D6E8FF"
1430WIDTH="100%"
1431CELLPADDING="6"
1432><TR
1433><TD
1434><PRE
1435CLASS="PROGRAMLISTING"
1436>void htmlParseElement (<A
1437HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
1438>htmlParserCtxtPtr</A
1439> ctxt);</PRE
1440></TD
1441></TR
1442></TABLE
1443><P
1444>parse an HTML element, this is highly recursive</P
1445><P
1446>[39] element ::= EmptyElemTag | STag content ETag</P
1447><P
1448>[41] Attribute ::= Name Eq AttValue</P
1449><P
1450></P
1451><DIV
1452CLASS="INFORMALTABLE"
1453><P
1454></P
1455><TABLE
1456BORDER="0"
1457WIDTH="100%"
1458BGCOLOR="#FFD0D0"
1459CELLSPACING="0"
1460CELLPADDING="4"
1461CLASS="CALSTABLE"
1462><TR
1463><TD
1464WIDTH="20%"
1465ALIGN="RIGHT"
1466VALIGN="TOP"
1467><TT
1468CLASS="PARAMETER"
1469><I
1470>ctxt</I
1471></TT
1472>&nbsp;:</TD
1473><TD
1474WIDTH="80%"
1475ALIGN="LEFT"
1476VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001477> an HTML parser context</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001478></TR
1479></TABLE
1480><P
1481></P
1482></DIV
1483></DIV
1484><HR><DIV
1485CLASS="REFSECT2"
1486><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001487NAME="AEN9871"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001488></A
1489><H3
1490><A
1491NAME="HTMLSAXPARSEDOC"
1492></A
1493>htmlSAXParseDoc ()</H3
1494><TABLE
1495BORDER="0"
1496BGCOLOR="#D6E8FF"
1497WIDTH="100%"
1498CELLPADDING="6"
1499><TR
1500><TD
1501><PRE
1502CLASS="PROGRAMLISTING"
1503><A
1504HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1505>htmlDocPtr</A
1506> htmlSAXParseDoc (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +00001507HREF="gnome-xml-tree.html#XMLCHAR"
1508>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001509> *cur,
1510 const char *encoding,
1511 <A
1512HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
1513>htmlSAXHandlerPtr</A
1514> sax,
1515 void *userData);</PRE
1516></TD
1517></TR
1518></TABLE
1519><P
1520>parse an HTML in-memory document and build a tree.
1521It use the given SAX function block to handle the parsing callback.
1522If sax is NULL, fallback to the default DOM tree building routines.</P
1523><P
1524></P
1525><DIV
1526CLASS="INFORMALTABLE"
1527><P
1528></P
1529><TABLE
1530BORDER="0"
1531WIDTH="100%"
1532BGCOLOR="#FFD0D0"
1533CELLSPACING="0"
1534CELLPADDING="4"
1535CLASS="CALSTABLE"
1536><TR
1537><TD
1538WIDTH="20%"
1539ALIGN="RIGHT"
1540VALIGN="TOP"
1541><TT
1542CLASS="PARAMETER"
1543><I
1544>cur</I
1545></TT
1546>&nbsp;:</TD
1547><TD
1548WIDTH="80%"
1549ALIGN="LEFT"
1550VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001551> a pointer to an array of xmlChar</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001552></TR
1553><TR
1554><TD
1555WIDTH="20%"
1556ALIGN="RIGHT"
1557VALIGN="TOP"
1558><TT
1559CLASS="PARAMETER"
1560><I
1561>encoding</I
1562></TT
1563>&nbsp;:</TD
1564><TD
1565WIDTH="80%"
1566ALIGN="LEFT"
1567VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001568> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001569></TR
1570><TR
1571><TD
1572WIDTH="20%"
1573ALIGN="RIGHT"
1574VALIGN="TOP"
1575><TT
1576CLASS="PARAMETER"
1577><I
1578>sax</I
1579></TT
1580>&nbsp;:</TD
1581><TD
1582WIDTH="80%"
1583ALIGN="LEFT"
1584VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001585> the SAX handler block</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001586></TR
1587><TR
1588><TD
1589WIDTH="20%"
1590ALIGN="RIGHT"
1591VALIGN="TOP"
1592><TT
1593CLASS="PARAMETER"
1594><I
1595>userData</I
1596></TT
1597>&nbsp;:</TD
1598><TD
1599WIDTH="80%"
1600ALIGN="LEFT"
1601VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001602> if using SAX, this pointer will be provided on callbacks. </TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001603></TR
1604><TR
1605><TD
1606WIDTH="20%"
1607ALIGN="RIGHT"
1608VALIGN="TOP"
1609><I
1610CLASS="EMPHASIS"
1611>Returns</I
1612> :</TD
1613><TD
1614WIDTH="80%"
1615ALIGN="LEFT"
1616VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001617>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001618></TR
1619></TABLE
1620><P
1621></P
1622></DIV
1623></DIV
1624><HR><DIV
1625CLASS="REFSECT2"
1626><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001627NAME="AEN9905"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001628></A
1629><H3
1630><A
1631NAME="HTMLPARSEDOC"
1632></A
1633>htmlParseDoc ()</H3
1634><TABLE
1635BORDER="0"
1636BGCOLOR="#D6E8FF"
1637WIDTH="100%"
1638CELLPADDING="6"
1639><TR
1640><TD
1641><PRE
1642CLASS="PROGRAMLISTING"
1643><A
1644HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1645>htmlDocPtr</A
1646> htmlParseDoc (<A
Daniel Veillarddd6b3671999-09-23 22:19:22 +00001647HREF="gnome-xml-tree.html#XMLCHAR"
1648>xmlChar</A
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001649> *cur,
1650 const char *encoding);</PRE
1651></TD
1652></TR
1653></TABLE
1654><P
1655>parse an HTML in-memory document and build a tree.</P
1656><P
1657></P
1658><DIV
1659CLASS="INFORMALTABLE"
1660><P
1661></P
1662><TABLE
1663BORDER="0"
1664WIDTH="100%"
1665BGCOLOR="#FFD0D0"
1666CELLSPACING="0"
1667CELLPADDING="4"
1668CLASS="CALSTABLE"
1669><TR
1670><TD
1671WIDTH="20%"
1672ALIGN="RIGHT"
1673VALIGN="TOP"
1674><TT
1675CLASS="PARAMETER"
1676><I
1677>cur</I
1678></TT
1679>&nbsp;:</TD
1680><TD
1681WIDTH="80%"
1682ALIGN="LEFT"
1683VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001684> a pointer to an array of xmlChar</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001685></TR
1686><TR
1687><TD
1688WIDTH="20%"
1689ALIGN="RIGHT"
1690VALIGN="TOP"
1691><TT
1692CLASS="PARAMETER"
1693><I
1694>encoding</I
1695></TT
1696>&nbsp;:</TD
1697><TD
1698WIDTH="80%"
1699ALIGN="LEFT"
1700VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001701> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001702></TR
1703><TR
1704><TD
1705WIDTH="20%"
1706ALIGN="RIGHT"
1707VALIGN="TOP"
1708><I
1709CLASS="EMPHASIS"
1710>Returns</I
1711> :</TD
1712><TD
1713WIDTH="80%"
1714ALIGN="LEFT"
1715VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001716>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001717></TR
1718></TABLE
1719><P
1720></P
1721></DIV
1722></DIV
1723><HR><DIV
1724CLASS="REFSECT2"
1725><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001726NAME="AEN9930"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001727></A
1728><H3
1729><A
1730NAME="HTMLSAXPARSEFILE"
1731></A
1732>htmlSAXParseFile ()</H3
1733><TABLE
1734BORDER="0"
1735BGCOLOR="#D6E8FF"
1736WIDTH="100%"
1737CELLPADDING="6"
1738><TR
1739><TD
1740><PRE
1741CLASS="PROGRAMLISTING"
1742><A
1743HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1744>htmlDocPtr</A
1745> htmlSAXParseFile (const char *filename,
1746 const char *encoding,
1747 <A
1748HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
1749>htmlSAXHandlerPtr</A
1750> sax,
1751 void *userData);</PRE
1752></TD
1753></TR
1754></TABLE
1755><P
1756>parse an HTML file and build a tree. Automatic support for ZLIB/Compress
1757compressed document is provided by default if found at compile-time.
1758It use the given SAX function block to handle the parsing callback.
1759If sax is NULL, fallback to the default DOM tree building routines.</P
1760><P
1761></P
1762><DIV
1763CLASS="INFORMALTABLE"
1764><P
1765></P
1766><TABLE
1767BORDER="0"
1768WIDTH="100%"
1769BGCOLOR="#FFD0D0"
1770CELLSPACING="0"
1771CELLPADDING="4"
1772CLASS="CALSTABLE"
1773><TR
1774><TD
1775WIDTH="20%"
1776ALIGN="RIGHT"
1777VALIGN="TOP"
1778><TT
1779CLASS="PARAMETER"
1780><I
1781>filename</I
1782></TT
1783>&nbsp;:</TD
1784><TD
1785WIDTH="80%"
1786ALIGN="LEFT"
1787VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001788> the filename</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001789></TR
1790><TR
1791><TD
1792WIDTH="20%"
1793ALIGN="RIGHT"
1794VALIGN="TOP"
1795><TT
1796CLASS="PARAMETER"
1797><I
1798>encoding</I
1799></TT
1800>&nbsp;:</TD
1801><TD
1802WIDTH="80%"
1803ALIGN="LEFT"
1804VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001805> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001806></TR
1807><TR
1808><TD
1809WIDTH="20%"
1810ALIGN="RIGHT"
1811VALIGN="TOP"
1812><TT
1813CLASS="PARAMETER"
1814><I
1815>sax</I
1816></TT
1817>&nbsp;:</TD
1818><TD
1819WIDTH="80%"
1820ALIGN="LEFT"
1821VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001822> the SAX handler block</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001823></TR
1824><TR
1825><TD
1826WIDTH="20%"
1827ALIGN="RIGHT"
1828VALIGN="TOP"
1829><TT
1830CLASS="PARAMETER"
1831><I
1832>userData</I
1833></TT
1834>&nbsp;:</TD
1835><TD
1836WIDTH="80%"
1837ALIGN="LEFT"
1838VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001839> if using SAX, this pointer will be provided on callbacks. </TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001840></TR
1841><TR
1842><TD
1843WIDTH="20%"
1844ALIGN="RIGHT"
1845VALIGN="TOP"
1846><I
1847CLASS="EMPHASIS"
1848>Returns</I
1849> :</TD
1850><TD
1851WIDTH="80%"
1852ALIGN="LEFT"
1853VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001854>the resulting document tree</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001855></TR
1856></TABLE
1857><P
1858></P
1859></DIV
1860></DIV
1861><HR><DIV
1862CLASS="REFSECT2"
1863><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001864NAME="AEN9963"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001865></A
1866><H3
1867><A
1868NAME="HTMLPARSEFILE"
1869></A
1870>htmlParseFile ()</H3
1871><TABLE
1872BORDER="0"
1873BGCOLOR="#D6E8FF"
1874WIDTH="100%"
1875CELLPADDING="6"
1876><TR
1877><TD
1878><PRE
1879CLASS="PROGRAMLISTING"
1880><A
1881HREF="gnome-xml-htmlparser.html#HTMLDOCPTR"
1882>htmlDocPtr</A
1883> htmlParseFile (const char *filename,
1884 const char *encoding);</PRE
1885></TD
1886></TR
1887></TABLE
1888><P
1889>parse an HTML file and build a tree. Automatic support for ZLIB/Compress
1890compressed document is provided by default if found at compile-time.</P
1891><P
1892></P
1893><DIV
1894CLASS="INFORMALTABLE"
1895><P
1896></P
1897><TABLE
1898BORDER="0"
1899WIDTH="100%"
1900BGCOLOR="#FFD0D0"
1901CELLSPACING="0"
1902CELLPADDING="4"
1903CLASS="CALSTABLE"
1904><TR
1905><TD
1906WIDTH="20%"
1907ALIGN="RIGHT"
1908VALIGN="TOP"
1909><TT
1910CLASS="PARAMETER"
1911><I
1912>filename</I
1913></TT
1914>&nbsp;:</TD
1915><TD
1916WIDTH="80%"
1917ALIGN="LEFT"
1918VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001919> the filename</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001920></TR
1921><TR
1922><TD
1923WIDTH="20%"
1924ALIGN="RIGHT"
1925VALIGN="TOP"
1926><TT
1927CLASS="PARAMETER"
1928><I
1929>encoding</I
1930></TT
1931>&nbsp;:</TD
1932><TD
1933WIDTH="80%"
1934ALIGN="LEFT"
1935VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001936> a free form C string describing the HTML document encoding, or NULL</TD
Daniel Veillard1566d3a1999-07-15 14:24:29 +00001937></TR
1938><TR
1939><TD
1940WIDTH="20%"
1941ALIGN="RIGHT"
1942VALIGN="TOP"
1943><I
1944CLASS="EMPHASIS"
1945>Returns</I
1946> :</TD
1947><TD
1948WIDTH="80%"
1949ALIGN="LEFT"
1950VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00001951>the resulting document tree</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00001952></TR
1953></TABLE
1954><P
1955></P
1956></DIV
1957></DIV
1958><HR><DIV
1959CLASS="REFSECT2"
1960><A
Daniel Veillard503b8932001-01-05 06:36:31 +00001961NAME="AEN9987"
Daniel Veillarde46e20d2000-07-14 15:02:46 +00001962></A
1963><H3
1964><A
1965NAME="UTF8TOHTML"
1966></A
1967>UTF8ToHtml ()</H3
1968><TABLE
1969BORDER="0"
1970BGCOLOR="#D6E8FF"
1971WIDTH="100%"
1972CELLPADDING="6"
1973><TR
1974><TD
1975><PRE
1976CLASS="PROGRAMLISTING"
1977>int UTF8ToHtml (unsigned char *out,
1978 int *outlen,
1979 unsigned char *in,
1980 int *inlen);</PRE
1981></TD
1982></TR
1983></TABLE
1984><P
1985>Take a block of UTF-8 chars in and try to convert it to an ASCII
1986plus HTML entities block of chars out.</P
1987><P
1988></P
1989><DIV
1990CLASS="INFORMALTABLE"
1991><P
1992></P
1993><TABLE
1994BORDER="0"
1995WIDTH="100%"
1996BGCOLOR="#FFD0D0"
1997CELLSPACING="0"
1998CELLPADDING="4"
1999CLASS="CALSTABLE"
2000><TR
2001><TD
2002WIDTH="20%"
2003ALIGN="RIGHT"
2004VALIGN="TOP"
2005><TT
2006CLASS="PARAMETER"
2007><I
2008>out</I
2009></TT
2010>&nbsp;:</TD
2011><TD
2012WIDTH="80%"
2013ALIGN="LEFT"
2014VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002015> a pointer to an array of bytes to store the result</TD
Daniel Veillarde46e20d2000-07-14 15:02:46 +00002016></TR
2017><TR
2018><TD
2019WIDTH="20%"
2020ALIGN="RIGHT"
2021VALIGN="TOP"
2022><TT
2023CLASS="PARAMETER"
2024><I
2025>outlen</I
2026></TT
2027>&nbsp;:</TD
2028><TD
2029WIDTH="80%"
2030ALIGN="LEFT"
2031VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002032> the length of <TT
2033CLASS="PARAMETER"
2034><I
2035>out</I
2036></TT
2037></TD
Daniel Veillarde46e20d2000-07-14 15:02:46 +00002038></TR
2039><TR
2040><TD
2041WIDTH="20%"
2042ALIGN="RIGHT"
2043VALIGN="TOP"
2044><TT
2045CLASS="PARAMETER"
2046><I
2047>in</I
2048></TT
2049>&nbsp;:</TD
2050><TD
2051WIDTH="80%"
2052ALIGN="LEFT"
2053VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002054> a pointer to an array of UTF-8 chars</TD
Daniel Veillarde46e20d2000-07-14 15:02:46 +00002055></TR
2056><TR
2057><TD
2058WIDTH="20%"
2059ALIGN="RIGHT"
2060VALIGN="TOP"
2061><TT
2062CLASS="PARAMETER"
2063><I
2064>inlen</I
2065></TT
2066>&nbsp;:</TD
2067><TD
2068WIDTH="80%"
2069ALIGN="LEFT"
2070VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002071> the length of <TT
2072CLASS="PARAMETER"
2073><I
2074>in</I
2075></TT
2076></TD
Daniel Veillarde46e20d2000-07-14 15:02:46 +00002077></TR
2078><TR
2079><TD
2080WIDTH="20%"
2081ALIGN="RIGHT"
2082VALIGN="TOP"
2083><I
2084CLASS="EMPHASIS"
2085>Returns</I
2086> :</TD
2087><TD
2088WIDTH="80%"
2089ALIGN="LEFT"
2090VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002091>0 if success, -2 if the transcoding fails, or -1 otherwise
2092The value of <TT
2093CLASS="PARAMETER"
2094><I
2095>inlen</I
2096></TT
2097> after return is the number of octets consumed
2098as the return value is positive, else unpredictiable.
2099The value of <TT
2100CLASS="PARAMETER"
2101><I
2102>outlen</I
2103></TT
2104> after return is the number of octets consumed.</TD
Daniel Veillarde46e20d2000-07-14 15:02:46 +00002105></TR
2106></TABLE
2107><P
2108></P
2109></DIV
2110></DIV
2111><HR><DIV
2112CLASS="REFSECT2"
2113><A
Daniel Veillard503b8932001-01-05 06:36:31 +00002114NAME="AEN10022"
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002115></A
2116><H3
2117><A
2118NAME="HTMLENCODEENTITIES"
2119></A
2120>htmlEncodeEntities ()</H3
2121><TABLE
2122BORDER="0"
2123BGCOLOR="#D6E8FF"
2124WIDTH="100%"
2125CELLPADDING="6"
2126><TR
2127><TD
2128><PRE
2129CLASS="PROGRAMLISTING"
2130>int htmlEncodeEntities (unsigned char *out,
2131 int *outlen,
2132 unsigned char *in,
2133 int *inlen,
2134 int quoteChar);</PRE
2135></TD
2136></TR
2137></TABLE
2138><P
2139>Take a block of UTF-8 chars in and try to convert it to an ASCII
2140plus HTML entities block of chars out.</P
2141><P
2142></P
2143><DIV
2144CLASS="INFORMALTABLE"
2145><P
2146></P
2147><TABLE
2148BORDER="0"
2149WIDTH="100%"
2150BGCOLOR="#FFD0D0"
2151CELLSPACING="0"
2152CELLPADDING="4"
2153CLASS="CALSTABLE"
2154><TR
2155><TD
2156WIDTH="20%"
2157ALIGN="RIGHT"
2158VALIGN="TOP"
2159><TT
2160CLASS="PARAMETER"
2161><I
2162>out</I
2163></TT
2164>&nbsp;:</TD
2165><TD
2166WIDTH="80%"
2167ALIGN="LEFT"
2168VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002169> a pointer to an array of bytes to store the result</TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002170></TR
2171><TR
2172><TD
2173WIDTH="20%"
2174ALIGN="RIGHT"
2175VALIGN="TOP"
2176><TT
2177CLASS="PARAMETER"
2178><I
2179>outlen</I
2180></TT
2181>&nbsp;:</TD
2182><TD
2183WIDTH="80%"
2184ALIGN="LEFT"
2185VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002186> the length of <TT
2187CLASS="PARAMETER"
2188><I
2189>out</I
2190></TT
2191></TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002192></TR
2193><TR
2194><TD
2195WIDTH="20%"
2196ALIGN="RIGHT"
2197VALIGN="TOP"
2198><TT
2199CLASS="PARAMETER"
2200><I
2201>in</I
2202></TT
2203>&nbsp;:</TD
2204><TD
2205WIDTH="80%"
2206ALIGN="LEFT"
2207VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002208> a pointer to an array of UTF-8 chars</TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002209></TR
2210><TR
2211><TD
2212WIDTH="20%"
2213ALIGN="RIGHT"
2214VALIGN="TOP"
2215><TT
2216CLASS="PARAMETER"
2217><I
2218>inlen</I
2219></TT
2220>&nbsp;:</TD
2221><TD
2222WIDTH="80%"
2223ALIGN="LEFT"
2224VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002225> the length of <TT
2226CLASS="PARAMETER"
2227><I
2228>in</I
2229></TT
2230></TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002231></TR
2232><TR
2233><TD
2234WIDTH="20%"
2235ALIGN="RIGHT"
2236VALIGN="TOP"
2237><TT
2238CLASS="PARAMETER"
2239><I
2240>quoteChar</I
2241></TT
2242>&nbsp;:</TD
2243><TD
2244WIDTH="80%"
2245ALIGN="LEFT"
2246VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002247> the quote character to escape (' or ") or zero.</TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002248></TR
2249><TR
2250><TD
2251WIDTH="20%"
2252ALIGN="RIGHT"
2253VALIGN="TOP"
2254><I
2255CLASS="EMPHASIS"
2256>Returns</I
2257> :</TD
2258><TD
2259WIDTH="80%"
2260ALIGN="LEFT"
2261VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002262>0 if success, -2 if the transcoding fails, or -1 otherwise
2263The value of <TT
2264CLASS="PARAMETER"
2265><I
2266>inlen</I
2267></TT
2268> after return is the number of octets consumed
2269as the return value is positive, else unpredictiable.
2270The value of <TT
2271CLASS="PARAMETER"
2272><I
2273>outlen</I
2274></TT
2275> after return is the number of octets consumed.</TD
Daniel Veillard3bff2b02000-10-01 20:33:47 +00002276></TR
2277></TABLE
2278><P
2279></P
2280></DIV
2281></DIV
2282><HR><DIV
2283CLASS="REFSECT2"
2284><A
Daniel Veillard503b8932001-01-05 06:36:31 +00002285NAME="AEN10061"
Daniel Veillard29a11cc2000-10-25 13:32:39 +00002286></A
2287><H3
2288><A
2289NAME="HTMLISSCRIPTATTRIBUTE"
2290></A
2291>htmlIsScriptAttribute ()</H3
2292><TABLE
2293BORDER="0"
2294BGCOLOR="#D6E8FF"
2295WIDTH="100%"
2296CELLPADDING="6"
2297><TR
2298><TD
2299><PRE
2300CLASS="PROGRAMLISTING"
2301>int htmlIsScriptAttribute (const <A
2302HREF="gnome-xml-tree.html#XMLCHAR"
2303>xmlChar</A
2304> *name);</PRE
2305></TD
2306></TR
2307></TABLE
2308><P
2309>Check if an attribute is of content type Script</P
2310><P
2311></P
2312><DIV
2313CLASS="INFORMALTABLE"
2314><P
2315></P
2316><TABLE
2317BORDER="0"
2318WIDTH="100%"
2319BGCOLOR="#FFD0D0"
2320CELLSPACING="0"
2321CELLPADDING="4"
2322CLASS="CALSTABLE"
2323><TR
2324><TD
2325WIDTH="20%"
2326ALIGN="RIGHT"
2327VALIGN="TOP"
2328><TT
2329CLASS="PARAMETER"
2330><I
2331>name</I
2332></TT
2333>&nbsp;:</TD
2334><TD
2335WIDTH="80%"
2336ALIGN="LEFT"
2337VALIGN="TOP"
2338> an attribute name</TD
2339></TR
2340><TR
2341><TD
2342WIDTH="20%"
2343ALIGN="RIGHT"
2344VALIGN="TOP"
2345><I
2346CLASS="EMPHASIS"
2347>Returns</I
2348> :</TD
2349><TD
2350WIDTH="80%"
2351ALIGN="LEFT"
2352VALIGN="TOP"
2353>1 is the attribute is a script 0 otherwise</TD
2354></TR
2355></TABLE
2356><P
2357></P
2358></DIV
2359></DIV
2360><HR><DIV
2361CLASS="REFSECT2"
2362><A
Daniel Veillard503b8932001-01-05 06:36:31 +00002363NAME="AEN10081"
2364></A
2365><H3
2366><A
2367NAME="HTMLHANDLEOMITTEDELEM"
2368></A
2369>htmlHandleOmittedElem ()</H3
2370><TABLE
2371BORDER="0"
2372BGCOLOR="#D6E8FF"
2373WIDTH="100%"
2374CELLPADDING="6"
2375><TR
2376><TD
2377><PRE
2378CLASS="PROGRAMLISTING"
2379>int htmlHandleOmittedElem (int val);</PRE
2380></TD
2381></TR
2382></TABLE
2383><P
2384>Set and return the previous value for handling HTML omitted tags.</P
2385><P
2386></P
2387><DIV
2388CLASS="INFORMALTABLE"
2389><P
2390></P
2391><TABLE
2392BORDER="0"
2393WIDTH="100%"
2394BGCOLOR="#FFD0D0"
2395CELLSPACING="0"
2396CELLPADDING="4"
2397CLASS="CALSTABLE"
2398><TR
2399><TD
2400WIDTH="20%"
2401ALIGN="RIGHT"
2402VALIGN="TOP"
2403><TT
2404CLASS="PARAMETER"
2405><I
2406>val</I
2407></TT
2408>&nbsp;:</TD
2409><TD
2410WIDTH="80%"
2411ALIGN="LEFT"
2412VALIGN="TOP"
2413> int 0 or 1 </TD
2414></TR
2415><TR
2416><TD
2417WIDTH="20%"
2418ALIGN="RIGHT"
2419VALIGN="TOP"
2420><I
2421CLASS="EMPHASIS"
2422>Returns</I
2423> :</TD
2424><TD
2425WIDTH="80%"
2426ALIGN="LEFT"
2427VALIGN="TOP"
2428>the last value for 0 for no handling, 1 for auto insertion.</TD
2429></TR
2430></TABLE
2431><P
2432></P
2433></DIV
2434></DIV
2435><HR><DIV
2436CLASS="REFSECT2"
2437><A
2438NAME="AEN10100"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002439></A
2440><H3
2441><A
2442NAME="HTMLFREEPARSERCTXT"
2443></A
2444>htmlFreeParserCtxt ()</H3
2445><TABLE
2446BORDER="0"
2447BGCOLOR="#D6E8FF"
2448WIDTH="100%"
2449CELLPADDING="6"
2450><TR
2451><TD
2452><PRE
2453CLASS="PROGRAMLISTING"
2454>void htmlFreeParserCtxt (<A
2455HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
2456>htmlParserCtxtPtr</A
2457> ctxt);</PRE
2458></TD
2459></TR
2460></TABLE
2461><P
2462>Free all the memory used by a parser context. However the parsed
2463document in ctxt-&gt;myDoc is not freed.</P
2464><P
2465></P
2466><DIV
2467CLASS="INFORMALTABLE"
2468><P
2469></P
2470><TABLE
2471BORDER="0"
2472WIDTH="100%"
2473BGCOLOR="#FFD0D0"
2474CELLSPACING="0"
2475CELLPADDING="4"
2476CLASS="CALSTABLE"
2477><TR
2478><TD
2479WIDTH="20%"
2480ALIGN="RIGHT"
2481VALIGN="TOP"
2482><TT
2483CLASS="PARAMETER"
2484><I
2485>ctxt</I
2486></TT
2487>&nbsp;:</TD
2488><TD
2489WIDTH="80%"
2490ALIGN="LEFT"
2491VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002492> an HTML parser context</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002493></TR
2494></TABLE
2495><P
2496></P
2497></DIV
2498></DIV
2499><HR><DIV
2500CLASS="REFSECT2"
2501><A
Daniel Veillard503b8932001-01-05 06:36:31 +00002502NAME="AEN10116"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002503></A
2504><H3
2505><A
2506NAME="HTMLCREATEPUSHPARSERCTXT"
2507></A
2508>htmlCreatePushParserCtxt ()</H3
2509><TABLE
2510BORDER="0"
2511BGCOLOR="#D6E8FF"
2512WIDTH="100%"
2513CELLPADDING="6"
2514><TR
2515><TD
2516><PRE
2517CLASS="PROGRAMLISTING"
2518><A
2519HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
2520>htmlParserCtxtPtr</A
2521> htmlCreatePushParserCtxt (<A
2522HREF="gnome-xml-htmlparser.html#HTMLSAXHANDLERPTR"
2523>htmlSAXHandlerPtr</A
2524> sax,
2525 void *user_data,
2526 const char *chunk,
2527 int size,
2528 const char *filename,
2529 <A
2530HREF="gnome-xml-encoding.html#XMLCHARENCODING"
2531>xmlCharEncoding</A
2532> enc);</PRE
2533></TD
2534></TR
2535></TABLE
2536><P
2537>Create a parser context for using the HTML parser in push mode
2538To allow content encoding detection, <TT
2539CLASS="PARAMETER"
2540><I
2541>size</I
2542></TT
2543> should be &gt;= 4
2544The value of <TT
2545CLASS="PARAMETER"
2546><I
2547>filename</I
2548></TT
2549> is used for fetching external entities
2550and error/warning reports.</P
2551><P
2552></P
2553><DIV
2554CLASS="INFORMALTABLE"
2555><P
2556></P
2557><TABLE
2558BORDER="0"
2559WIDTH="100%"
2560BGCOLOR="#FFD0D0"
2561CELLSPACING="0"
2562CELLPADDING="4"
2563CLASS="CALSTABLE"
2564><TR
2565><TD
2566WIDTH="20%"
2567ALIGN="RIGHT"
2568VALIGN="TOP"
2569><TT
2570CLASS="PARAMETER"
2571><I
2572>sax</I
2573></TT
2574>&nbsp;:</TD
2575><TD
2576WIDTH="80%"
2577ALIGN="LEFT"
2578VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002579> a SAX handler</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002580></TR
2581><TR
2582><TD
2583WIDTH="20%"
2584ALIGN="RIGHT"
2585VALIGN="TOP"
2586><TT
2587CLASS="PARAMETER"
2588><I
2589>user_data</I
2590></TT
2591>&nbsp;:</TD
2592><TD
2593WIDTH="80%"
2594ALIGN="LEFT"
2595VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002596> The user data returned on SAX callbacks</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002597></TR
2598><TR
2599><TD
2600WIDTH="20%"
2601ALIGN="RIGHT"
2602VALIGN="TOP"
2603><TT
2604CLASS="PARAMETER"
2605><I
2606>chunk</I
2607></TT
2608>&nbsp;:</TD
2609><TD
2610WIDTH="80%"
2611ALIGN="LEFT"
2612VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002613> a pointer to an array of chars</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002614></TR
2615><TR
2616><TD
2617WIDTH="20%"
2618ALIGN="RIGHT"
2619VALIGN="TOP"
2620><TT
2621CLASS="PARAMETER"
2622><I
2623>size</I
2624></TT
2625>&nbsp;:</TD
2626><TD
2627WIDTH="80%"
2628ALIGN="LEFT"
2629VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002630> number of chars in the array</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002631></TR
2632><TR
2633><TD
2634WIDTH="20%"
2635ALIGN="RIGHT"
2636VALIGN="TOP"
2637><TT
2638CLASS="PARAMETER"
2639><I
2640>filename</I
2641></TT
2642>&nbsp;:</TD
2643><TD
2644WIDTH="80%"
2645ALIGN="LEFT"
2646VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002647> an optional file name or URI</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002648></TR
2649><TR
2650><TD
2651WIDTH="20%"
2652ALIGN="RIGHT"
2653VALIGN="TOP"
2654><TT
2655CLASS="PARAMETER"
2656><I
2657>enc</I
2658></TT
2659>&nbsp;:</TD
2660><TD
2661WIDTH="80%"
2662ALIGN="LEFT"
2663VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002664> an optional encoding</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002665></TR
2666><TR
2667><TD
2668WIDTH="20%"
2669ALIGN="RIGHT"
2670VALIGN="TOP"
2671><I
2672CLASS="EMPHASIS"
2673>Returns</I
2674> :</TD
2675><TD
2676WIDTH="80%"
2677ALIGN="LEFT"
2678VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002679>the new parser context or NULL</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002680></TR
2681></TABLE
2682><P
2683></P
2684></DIV
2685></DIV
2686><HR><DIV
2687CLASS="REFSECT2"
2688><A
Daniel Veillard503b8932001-01-05 06:36:31 +00002689NAME="AEN10160"
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002690></A
2691><H3
2692><A
2693NAME="HTMLPARSECHUNK"
2694></A
2695>htmlParseChunk ()</H3
2696><TABLE
2697BORDER="0"
2698BGCOLOR="#D6E8FF"
2699WIDTH="100%"
2700CELLPADDING="6"
2701><TR
2702><TD
2703><PRE
2704CLASS="PROGRAMLISTING"
2705>int htmlParseChunk (<A
2706HREF="gnome-xml-htmlparser.html#HTMLPARSERCTXTPTR"
2707>htmlParserCtxtPtr</A
2708> ctxt,
2709 const char *chunk,
2710 int size,
2711 int terminate);</PRE
2712></TD
2713></TR
2714></TABLE
2715><P
2716>Parse a Chunk of memory</P
2717><P
2718></P
2719><DIV
2720CLASS="INFORMALTABLE"
2721><P
2722></P
2723><TABLE
2724BORDER="0"
2725WIDTH="100%"
2726BGCOLOR="#FFD0D0"
2727CELLSPACING="0"
2728CELLPADDING="4"
2729CLASS="CALSTABLE"
2730><TR
2731><TD
2732WIDTH="20%"
2733ALIGN="RIGHT"
2734VALIGN="TOP"
2735><TT
2736CLASS="PARAMETER"
2737><I
2738>ctxt</I
2739></TT
2740>&nbsp;:</TD
2741><TD
2742WIDTH="80%"
2743ALIGN="LEFT"
2744VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002745> an XML parser context</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002746></TR
2747><TR
2748><TD
2749WIDTH="20%"
2750ALIGN="RIGHT"
2751VALIGN="TOP"
2752><TT
2753CLASS="PARAMETER"
2754><I
2755>chunk</I
2756></TT
2757>&nbsp;:</TD
2758><TD
2759WIDTH="80%"
2760ALIGN="LEFT"
2761VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002762> an char array</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002763></TR
2764><TR
2765><TD
2766WIDTH="20%"
2767ALIGN="RIGHT"
2768VALIGN="TOP"
2769><TT
2770CLASS="PARAMETER"
2771><I
2772>size</I
2773></TT
2774>&nbsp;:</TD
2775><TD
2776WIDTH="80%"
2777ALIGN="LEFT"
2778VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002779> the size in byte of the chunk</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002780></TR
2781><TR
2782><TD
2783WIDTH="20%"
2784ALIGN="RIGHT"
2785VALIGN="TOP"
2786><TT
2787CLASS="PARAMETER"
2788><I
2789>terminate</I
2790></TT
2791>&nbsp;:</TD
2792><TD
2793WIDTH="80%"
2794ALIGN="LEFT"
2795VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002796> last chunk indicator</TD
Daniel Veillard3f6f7f62000-06-30 17:58:25 +00002797></TR
2798><TR
2799><TD
2800WIDTH="20%"
2801ALIGN="RIGHT"
2802VALIGN="TOP"
2803><I
2804CLASS="EMPHASIS"
2805>Returns</I
2806> :</TD
2807><TD
2808WIDTH="80%"
2809ALIGN="LEFT"
2810VALIGN="TOP"
Daniel Veillardb732a0e2000-10-15 11:27:01 +00002811>zero if no error, the xmlParserErrors otherwise.</TD
Daniel Veillard437b87b2000-01-03 17:30:46 +00002812></TR
2813></TABLE
2814><P
2815></P
2816></DIV
2817></DIV
Daniel Veillard1566d3a1999-07-15 14:24:29 +00002818></DIV
2819><DIV
2820CLASS="NAVFOOTER"
Daniel Veillard00fdf371999-10-08 09:40:39 +00002821><BR
2822CLEAR="all"><BR><TABLE
Daniel Veillard1566d3a1999-07-15 14:24:29 +00002823WIDTH="100%"
2824BORDER="0"
2825BGCOLOR="#000000"
2826CELLPADDING="1"
2827CELLSPACING="0"
2828><TR
2829><TD
2830WIDTH="25%"
2831BGCOLOR="#C00000"
2832ALIGN="left"
2833><A
Daniel Veillard503b8932001-01-05 06:36:31 +00002834HREF="gnome-xml-uri.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00002835><FONT
2836COLOR="#FFFFFF"
2837SIZE="3"
2838><B
2839>&#60;&#60;&#60; Previous Page</B
2840></FONT
2841></A
2842></TD
2843><TD
2844WIDTH="25%"
2845BGCOLOR="#0000C0"
2846ALIGN="center"
2847><FONT
2848COLOR="#FFFFFF"
2849SIZE="3"
2850><B
2851><A
2852HREF="book1.html"
2853><FONT
2854COLOR="#FFFFFF"
2855SIZE="3"
2856><B
2857>Home</B
2858></FONT
2859></A
2860></B
2861></FONT
2862></TD
2863><TD
2864WIDTH="25%"
2865BGCOLOR="#00C000"
2866ALIGN="center"
2867><FONT
2868COLOR="#FFFFFF"
2869SIZE="3"
2870><B
2871><A
Daniel Veillard35008381999-10-25 13:15:52 +00002872HREF="libxml-lib.html"
Daniel Veillard1566d3a1999-07-15 14:24:29 +00002873><FONT
2874COLOR="#FFFFFF"
2875SIZE="3"
2876><B
2877>Up</B
2878></FONT
2879></A
2880></B
2881></FONT
2882></TD
2883><TD
2884WIDTH="25%"
2885BGCOLOR="#C00000"
2886ALIGN="right"
2887><A
2888HREF="gnome-xml-htmltree.html"
2889><FONT
2890COLOR="#FFFFFF"
2891SIZE="3"
2892><B
2893>Next Page &#62;&#62;&#62;</B
2894></FONT
2895></A
2896></TD
2897></TR
2898><TR
2899><TD
2900COLSPAN="2"
2901ALIGN="left"
2902><FONT
2903COLOR="#FFFFFF"
2904SIZE="3"
2905><B
Daniel Veillard503b8932001-01-05 06:36:31 +00002906>uri</B
Daniel Veillard1566d3a1999-07-15 14:24:29 +00002907></FONT
2908></TD
2909><TD
2910COLSPAN="2"
2911ALIGN="right"
2912><FONT
2913COLOR="#FFFFFF"
2914SIZE="3"
2915><B
2916>HTMLtree</B
2917></FONT
2918></TD
2919></TR
2920></TABLE
2921></DIV
2922></BODY
2923></HTML
2924>