Every programming-language (let's take Perl, for example...) is going to provide you with a very large
infrastructure of existing code that can handle both HTML and, separately, XML.
Using Perl as a typical example, "everything in the world can be found in an archive called CPAN." (Every other language you can name has a similar archive of actively tested and maintained code.)
has a favorite acronym: TMTOWTDI = "There's More Than One Way To Do It."
If I were using Perl, then I know that a CPAN-library unit called CGI
will provide anything
I could possibly require in the way of interpreting that HTML-envelope ... everything from that HTTP/1.1 200 OK
line through the first blank line. In other words, I don't have to "write" any
code of my own to do that.
also provides all of the low-level functionality that I may need to send the HTTP reply back.
The same is true of the XML: I don't have to write anything new. In fact, CPAN gives me many dozens
of off-the-shelf tools both for building and for interpreting ("parsing") XML.
On top of that,
there's layer-upon-layer of existing
, tested software that I can "simply use." Stuff that I absolutely do not have to write. Stuff that is used by tens-of-thousands of active web sites "just like mine." Or, yours. Frameworks for complete web-sites or for any portion thereof.
Q: "How do I write a subroutine|program to do this-or-that?"
Dictum Ne Agas: "Do Not Do A Thing Already Done."