(Not really an answer to your question, but others have addressed that, and this is related)
Assuming your main program doesn't do anything user specific, why put the burden of program execution on the user? The sites I work on have their dynamic scripts as scripts, and the bulk of the html generated just as your is, except that I save the output to a branch the webserver serves up.

That didn't sound right. Let me offer an example:

/usr/local/apache/content holds the "content" html just as your /perl/index.html does.

/usr/local/apache/htdocs is where the webserver serves up pages.

My program wraps the content html in headers and footers (as well as running the whole thing through Template Toolkit), then saves the result as an .html somwhere under /usr/local/apache/htdocs/

Thus my users don't have any execution time for "flat" pages, only with actual dynamic content, but my unit doesn't have to maintain the navigation on every page because the build process drops it in place. Our setup is a little complex, with a database holding the relationships between pages, and the build process generating a different local navigation for each page, but you can season to taste.

It's not a concept I can take any credit for, it's been done for a while (Laziness, after all). Template Toolkit ships with a helper program that does something like this, and it's a simple script to do it with most other template systems (I only have experience with Template::Toolkit and HTML::Template, but the concept holds true for anything with HTML output).


In reply to Re: Minimizing paths? by swiftone
in thread Minimizing paths? by Anonymous Monk

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.