Actually, I believe that it helps to do a use cgi qw(-compile: all) as this
will pre-compile the entire module (which makes it go a bit faster for it's
first request).

   Issac

----- Original Message -----
From: "Purcell, Scott" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, June 27, 2001 17:29
Subject: Startup.pl File Q


> Mod_perl version: 1.25_01-dev
> Perl version:         5.6.1
> Apache Version:  1.3.20
> OS:                    NT
>
> I am in the apache book and I am doing some hacking. In my startup.pl
file,
> I put 'use CG qw(:standard); along with some other modules.
> Anyway, then I typed that little dittie below, and commented out the $use
> CGI (since I thought it would be loaded in the startup.pl file).
>
> It does not work. Are the items in the startup.pl file only used with
> handlers?
>
> Thanks
> Scott
>
>
>
> ### code below just for reference #####
>
> #! /usr/local/bin/perl
>
> #use CGI qw(:standard);
> use strict;
>
> my $name = param('name') || 'Anonymous';
>
> print header(),
> start_html(-title=>'Yo!',-bgcolor=>'blue'),
> h1("Hello $name"),
> p(
> "To change your name, enter it into the text field below and press",
>     em("change name.")
> ),
> start_form(),
> "Name: ",textfield(-name=>'name',-value=>'Anonymous'),
> submit(-value=>'Change Name'),
> end_form(),
> hr(),
> end_html();
>
> Scott Purcell
>

Reply via email to