Re: Server-Side JavaScript? (Was Re: JAVAscript)

by "David Meadows" <david(at)goldenheroes.softnet.co.uk>

 Date:  Sat, 19 Sep 1998 13:22:00 +0100
 To:  "Ryan Fischer" <fischer(at)email.unc.edu>,
"Michelle L. Kinsey-Clinton" <mkinsey(at)mindspring.com>
 Cc:  <hwg-theory(at)hwg.org>
  todo: View Thread, Original
Ryan Fischer <fischer(at)email.unc.edu> wrote:


>On Fri, 18 Sep 1998, (via HWG-Techniques)
>Michelle L. Kinsey-Clinton wrote:
[...]
>> technology. I'm more curious to hear why
>>you might use JavaScript on the back end
>>*as opposed to* things like CFM, ASP,
>>Perl/other CGI, etc. Anyone?
>
>Personally, I don't bother.  IMO, JavaScript
>was not initially created to be a Server-Side
>language.  It's just not meant to do the things
>Perl can do.  There's not really much you can
>say about it other than that.


Is this theory? Oh well, to give my comments a theoretical bias, I
will start with two axioms and advance a hypothesis ;-)

Axiom 1: Scripts (client-side or server-side) are used to modify a
document dynamically in response to user requests.

Axiom 2: Server-side scripts are preferable to client-side scripts
in all cases where you do not have total control over the client's
browsing environment.

I don't really know about Netscape's implementation of JavaScript,
but in Microsoft's ActiveX Scripting implementation, scripts
running inside a document on a web server can dynamically modify
that document before sending it to the client. This is not *as
opposed to* ASP, it is a fundamental part of ASP.

JScript or VBScript running on the server can access external
documents, databases, etc., and include them in the HTML page (or
evaluate data in them and use the results to modify the HTML
document).

I am not fully conversant with Perl, but I don't imagine it can do
anything that server-side ActiveX Scripting cannot also do.

The advantage of putting the script inside a HTML "shell" document
is that the "shell" is then relatively easy to modify (in your
favourite HTML editor). I believe that a document served by a Perl
script is 100% generated by the Perl script. So to modify any part
of the page, you have to re-write the Perl script (surely more
arduous than editing the HTML page?) I stand ready to be corrected
on this, because I really don't know Perl well enough and may be
misunderstanding how it works.


Oh yeah... I was gong to advance a hypothesis... uh...

    "Server-side ActiveX scripting is the best way to dynamically
create HTML documents"

(Well, that should stir up a few hornets' nests.)


--
David Meadows [ Technical Writer | Information Developer ]
DNRC Minister for Littorasy * david(at)goldenheroes.softnet.co.uk
"Mind, body, heart and soul: we've got rock and roll
 And there's nothing they can do" -- Ian Gillan, "Gypsy's Kiss"

HWG hwg-theory mailing list archives, maintained by Webmasters @ IWA