Re: [gdome] Parsing HTML documents?



Hello Bradley,

  gdome2 works only with well formed XML documents, the only released modules (wrt DOM specifications) are Main, Events and XPath: the HTML module is an old, not working and not maintained implementation.

If you deal only with well formed XHTML documents, you can use gdome2, otherwise, as Luca already said, libxml2 is the right choice for you.

Best regards,
  Paolo.

On Aug 16, 2009 10:59 PM, "Bradley Kite" <bradley kite gmail com> wrote:

Hello.

I have been looking for a C library that provides a DOM interface to
parsed HTML documents, however I have been struggling to make it work
the way that I'd like (probably because I'm trying to use it
incorrectly, no doubt!).

Firstly, can gdome be used to parse HTML documents? I am aware that
its more geared towards XML, which, although similar, has obvious
differences!

In any case, I'm using one of the examples as a start, however I'm
getting this error while calling parse():

parser error : StartTag: invalid element name
<!doctype html><head><title>

I guess the main question I have, is am I using the right tool? Or
should I be using something more suited to HTML? If so, would any body
have any recomendations? I need to be able to modify various
components of the DOM, and it needs to be written in C (or C++, but
preferably C).

Many thanks
--
Bradley Kite
_______________________________________________
gdome mailing list
gdome gnome org
http://mail.gnome.org/mailman/listinfo/gdome



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