RE: javascript within print "<

2001-06-12 Thread Tillema, Glenn
Here is how I do it; #!/usr/local/bin/perl -w use CGI; print header(); print "\n", " test script\n"; print < alert('test'); DONE print "\n"; cheers, Glenn Glenn Tillema [EMAIL PROTECTED] ADC Telecommunications, Inc. PO Box 1101, MS 508 Minneapolis, MN 55440-1101

RE: javascript within print "<

2001-06-13 Thread Tillema, Glenn
> As written, this script won't work. If you call the > 'header()' function directly, you need to > import this function from CGI. One way to do it is: > > use CGI qw/:standard/; It works in the script I copy and pasted from ... :) > Also, since you are already using CGI.pm, why not take >

RE: javascript within print "<

2001-06-14 Thread Tillema, Glenn
> The CGI module is not supposed to export any functions > without their being explicitly requested. > Maybe you have a version that someone else hacked? No matter. I honestly wouldn't know .. all of the functionality seems to be there. > > > Also, since you are already using CGI.pm, why not

RE: How to generate a table ?

2001-06-15 Thread Tillema, Glenn
> -Original Message- > From: Curtis Poe [mailto:[EMAIL PROTECTED]] > Sent: Friday, June 15, 2001 6:00 PM > To: [EMAIL PROTECTED] > Subject: RE: How to generate a table ? > > > Heh. I keep saying 'factor out common elements', but I > didn't bother to do it in my snippet :) > Curtis,

RE: How to generate a table ?

2001-06-15 Thread Tillema, Glenn
#!/usr/local/bin/perl -w use CGI qw/:standard *table/; $cust_id = "cust"; $acct = "account"; $title = "title"; %hofEntries = (1 => {label => "Customer Id", name => "NEWCUST_ID", def => $cust_id, size => "10",}, 2 =>

RE: Running CGI's locally

2001-06-19 Thread Tillema, Glenn
Adam, The scripts need to be run from a server that supports Perl and Perl scripts; usually this is Apache and Perl or Microsoft Internet Information Server and Perl. If you are interested in running a Web server and Perl on your own computer I would suggest you read-up on Apache for Win32 at h

RE: How to generate a table ?

2001-06-19 Thread Tillema, Glenn
> -Original Message- > From: Moon, John [mailto:[EMAIL PROTECTED]] > Sent: Monday, June 18, 2001 7:36 PM > To: Tillema, Glenn; 'Curtis Poe'; [EMAIL PROTECTED] > Subject: RE: How to generate a table ? > > > Glenn & Curtis; > > Thanks for the

RE: Extra ?

2001-06-21 Thread Tillema, Glenn
> > "Curtis" == Curtis Poe <[EMAIL PROTECTED]> writes: > > Curtis> my $foo_count = scalar @{[param('foo')]}; > > That's nice, but I prefer: > > my $foo_count = () = param('foo'); > > Less typing, less work for the machine. Less noise. More magic, > though. Oops, arguable on

RE: Extra ?

2001-06-21 Thread Tillema, Glenn
> >> my $foo_count = () = param('foo'); > > Tillema,> Let me guess ... param('foo') is assigned to a list > Tillema,>... the list is assigned > Tillema,> to $foo_count in a scalar context so the number of > Tillema,> elements are returned. > > Tillema,> Right? > > Probably simpler than that.

RE: Extra ?

2001-06-21 Thread Tillema, Glenn
> Tillema,> That's how it was phrased in the camel; "List > Tillema,> assignment in scalar context > Tillema,> returns the number of elements produced by the > Tillema,> expression on the _right_ side > Tillema,> of the assignment..." Your explanation certainly > Tillema,> goes into much more

inline substitution

2001-06-25 Thread Tillema, Glenn
Argh! I'm trying to replace underscores with '%20' when I print out a table header. Right now I'm getting 1's instead of the substituted string! I know I'm forgetting something .. what am I forgetting? BEGIN--Sample--code-- @serverColumns = qw{Server_Type Server_Name IP_Address Model Processor

RE: How to make a script run in the background on a Win32 machine

2001-07-11 Thread Tillema, Glenn
> From: Mark Ross [mailto:[EMAIL PROTECTED]] > Subject: How to make a script run in the background on a Win32 machine > > [---8<--- Run script in the background on a Win32 machine --8<--] Mark, I like to use Fire Daemon; http://www.firedaemon.com/. Fire Daemon helps you set up Perl scripts as s

Two Array into One Hash

2001-07-17 Thread Tillema, Glenn
I know there must be an easy way to do this but the solution evades me and I'm hoping someone here either knows the answer or can point me in the right direction so I can figure it out myself ... on to the question; I have two scalars, each contain a comma-seperated list of values; $scaOne = "1,

RE: Two Array into One Hash

2001-07-17 Thread Tillema, Glenn
Thanks Darren! I *knew* there was an easy way to do it! I rarely use slices that way so I can see why it hadn't occured to me. Oh, and yes, $scaOne and $scaTwo have the same number of fields in them. Glenn Glenn Tillema [EMAIL PROTECTED] ADC Telecommunications, Inc. PO Box

RE: Two Array into One Hash

2001-07-18 Thread Tillema, Glenn
> -Original Message- > From: Rachel Coleman [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, July 17, 2001 2:03 PM > To: [EMAIL PROTECTED] > Subject: Re: Two Array into One Hash > > Using the hash slice example in Learning Perl 2nd Edition, page 70, I > wrote the following script: [--8<-- exa

RE: error info...

2001-07-19 Thread Tillema, Glenn
Jext is a great editor too, written entirely in java, and is free. http://www.jext.org cheers, Glenn Glenn Tillema [EMAIL PROTECTED] ADC Telecommunications, Inc. PO Box 1101, MS 508 Minneapolis, MN 55440-1101 Learn about ADC - The Broadband Company - www.adc.com > -Or