savannah-hackers
[Top][All Lists]
Advanced

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

[Savannah-hackers] Re: html/css hackers: input requested


From: Jaime E. Villate
Subject: [Savannah-hackers] Re: html/css hackers: input requested
Date: Fri, 31 Jan 2003 17:19:00 +0000
User-agent: Mutt/1.2.5i

On Fri, Jan 17, 2003 at 12:46:12PM +0100, Mathieu Roy wrote:
> 
> In fact, the point is to generate static content. That can be done
> without XHTML/XSLT, but apparently there are several reason that make
> it easier with XHTML/XSLT.
> 
> Jaime, can you state (for my personal information) the advantages of
> XHTML/XSTL over simple XHTML/HTML generated by perl/bash or whatever
> language?

Hi Mathieu,
sorry for the late reply. Of course, you can make your own scripts to parse
XHTML. But it is a bit like reinventing the wheel. There are already some
excellent XML parsers available that will also check the syntax of the input
xhtml file; even if your script is free of bugs, it may fail because of a
syntax error in the input xhtml.

For some applications it is desirable to write your own script, but even in
those cases you should use existing libraries to parse XML. One of the nice
things about XML is that not only did they create a standard for the structure
of the document, but they also created a standard for the way the information
should be parsed: there are currently two standards, SAX and DOM, for different
purposes. The advantage of following a standard such as SAX is that if
for instance you write your scripts in Perl+SAX, some Japanese programmer
using C++ and SAX will understand very easily what you've done because the
methods are the same.

Cheers,
Jaime
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]