That particular URL format is characteristic of Vignette content-management products. It's been a while since I worked with their tools, but my recollection is that it works something like this.

Each of the four comma-delimited numbers has a specific meaning. The first one is normally 0 to use a cached version of a page if one exists, whereas a 1 indicates that the page should be rebuilt dynamically. The second number is the identifier of the template used to build the page content. The third number is the identifier of the content used to build the page. The fourth number has something to do with browser-specific versions of a page, but I've never seen it used in practice.

By varying the second number but keeping the third number constant, a producer can vary the template that controls content presentation while keeping the underlying content constant. By varying the third number but keeping the second number constant, a producer can vary the content that appears in a specific template.

I'm not familiar with how eWeek uses the "?kc=xxx" portion of the URL, but it may have something to do with tracking where a referral to a page originated, or perhaps user-specific state.

You mention you weren't sure whether commas are allowable in filenames. It probably depends on your OS, but in any case it doesn't likely matter, because the Vignette URLs do not correspond to real filenames. Instead, the URL above is essentially invoking a program with the parameters (0,3959,809353,00) and whatever's in kc, and that program returns the appropriate page.

You can accomplish something similar with perl and CGI. For example, if you want your site to have URLs like this:
http://www.mysite.com/show/14/22/56

You can do it by creating a script called show (no extension) in your docroot, then using the $ENV{PATH_INFO} variable to capture the /14/22/56 "parameters" that the script was invokved with. (This makes some assumptions that may not be true in practice, e.g. that your host will let you create an executable script in your docroot.)

Building a database- and template-driven site is indeed something worth exploring (though this particular URL syntax may not be the most effective for all applications). You may want to check out modules like HTML::Template and Template Toolkit to get an idea what's possible.

        $perlmonks{seattlejohn} = 'John Clyman';


In reply to Re: quasi-perl related ... more website design by seattlejohn
in thread quasi-perl related ... more website design by primus

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.