W3C home > Mailing lists > Public > www-lib@w3.org > April to June 2001

How can I evaluate attributes to unparsed HTML-Tags

From: Matthias Bernhardt <matthb@ais-ag.de>
Date: Fri, 4 May 2001 08:22:34 -0400 (EDT)
To: <www-lib@w3.org>
Message-ID: <Pine.LNX.4.31.0105041349190.619-100000@merlin>
Hello there,

I intend to extend HTML-Pages with a proprietary tag (no, it's
NOT a <blink>-Tag and it's only for internal use) with
attributes.

Documentation leads me as far as to register an
unparsedElementCallback routine. Thus I can find out whether
(and how often) the Tag exists in my Page. But how can I
evaluate attributes in my tag?

I wrote

  void unparsedBeginElement(
    HText *       HText,
    const char *  buffer,
    int           length )
  {
    printf("The tag <%s> appeared.\n",buf);
  };

After calling

  HText_registerUnparsedElementCallback(unparsedBeginElement);

my routine is called everytime my Tag appears:

  <html>
    <head>
      <title>Test</title>
      <mytag>
    </head>
    <body>
      Text
    </body>
  </html>

would cause it to print out

  The tag <mytag> appeared.

But I have no idea, how to evaluate attributes like in:

  <html>
    <head>
      <title>Test</title>
      <mytag attrib1="value1" attrib2="value2" test="123">
    </head>
    <body>
      Text
    </body>
  </html>


I already browsed the documentation but as I am a beginner in
Libwww I did not encounter a hint which I recognised as helpful.
So if anyone could give me an idea which sections contain
helpful information on this issue or which keywords I shall
look for, that might already help me very much.

With kind regards,

Matthias


----------------------------------------------------------------
Matthias Bernhardt         AIS GmbH         fon +49-561-30859-29
Softwareentwicklung      Rheinweg 7-9       fax +49-561-30859-39
Netzwerkbetreuung        34131 Kassel       elm matthb@ais-ag.de
Received on Friday, 4 May 2001 22:29:52 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2007 18:18:39 GMT