dda

"Say, does it make sense to prepare XML file, use it as a template, and then apply some transformation to it to convert it to HTML? Any advice is welcome."

A lot depends on the scale of the project, but we achived quite a lot with a CGI/XSLT combination, like you suggest. I would not recommend this approach for larger projects, but Matts excellent AxKit looks very good.

What we did was to use XML to communicate with a backend SAP system. The SAP system spoke in XML, so the CGI application used XML to speak with the SAP system. The applaction used the XML::LibXML module to manipulate input/output XML and then used XML::LibXSLT to convert XML to HTML.

If you like XML/XSLT then this is a nice way of doing things, and the we used Perl to feed things into and extract things from the XML before we transform it.

The application has been running now with multiple users for about 4 months, and on a 1Gz Linux box, it seems to perform quite well. We've not pushed it yet to find out how many simultaneous users it can deal with, but if we wanted a big system we'd have written it in mod_Perl, and probably used AxKit.

Update: Minor corrections.


--
ajt

In reply to Re: perl/XML development by ajt
in thread perl/XML development by dda

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.