Greetings!
I have successfully added the new functionality to the script I have
been upgrading. Now the old functionality doesn't work. When I try to
use it, I get an error page announcing Error 500, Internal Server
Error. The log file contains the following message:
Premature end of script
Last week, I requested help in a script that would compare two lists, and print the
results in a third list - the results being just the items that occured in BOTH lists.
You came thru with some good help. Posted below is the script I used - including some
slight modifications for my web site.
On Sat, Jan 11, 2003 at 09:41:37PM -0500, [EMAIL PROTECTED] wrote:
In a message dated 1/11/2003 8:55:37 PM Eastern Standard Time,
[EMAIL PROTECTED] writes:
When processing the form the date in this format 3/1/2003 is converted to
3%2F1%2F2003.
Can someone give me a regex to convert it
Can you provide the code?
You should print the header for your page.
The header always have 2 blank lines after, so you should use either:
print Location: $url\n\n;
or
print Content-type: text/html\n\n;
or
print eof;
Set-Cookie: name=value; path=/cgi-bin/; expires=Sun, 12-Jan-2003 17:02:20
GMT
I need to slice an array such that it gives me the first through the 4th to
last in a variable length array. I thought I could just do:
@comments[0..-4]
but Perl seems to choke on this. It's perfectly okay with a slice using two
negative #s:
@comments[-2..-4]
Anyone know why it doesn't
Bryan Harris wrote:
I need to slice an array such that it gives me the first through the 4th to
last in a variable length array. I thought I could just do:
@comments[0..-4]
but Perl seems to choke on this. It's perfectly okay with a slice using two
negative #s:
hi there!
I've got a problem with a complex data structure and hope you can help me.
I know that I can't have a hash whose values are arrays. So I tried to
build a hash of references to arrays.
I guess I've made some mistakes .
This is what my hash looks like:
%myHash = ();
# lots of
Nicole Seitz wrote:
hi there!
I've got a problem with a complex data structure and hope you can
help me.
I know that I can't have a hash whose values are arrays. So I tried
to build a hash of references to arrays.
I guess I've made some mistakes .
This is what my hash looks
Rob Dixon [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]...
Hi Bryan
Bryan Harris [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
I need to slice an array such that it gives me the first through the 4th
to
last in a variable length array. I
Hey, I have a slight dilemma which i'm struggling to overcome. Wondering if
anyone has any ideas on this..
I have a variable, for example's sake, say $variable. $variable has a load
of entries.
$variable = danneh blah dan etc danster;
What i want to do, without having to set the entire string
if (!$ARGV[0]){
die(you've forgotten to enter the file name\n);
}
if (!$ARGV[1]) {
$n = 9; # output 10 rows by default
}
else {
$n = $ARGV[1]-1;
}
what if the user enters, script.pl 8 ??? This wil try to open a file 8
and dump last 9 lines of it.
if( $#ARGV !=
Hi Nicole
Nicole Seitz [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
hi there!
I've got a problem with a complex data structure and hope you can help
me.
I know that I can't have a hash whose values are arrays. So I tried to
build a hash of references to
Dan wrote:
Hey, I have a slight dilemma which i'm struggling to overcome. Wondering if
anyone has any ideas on this..
I have a variable, for example's sake, say $variable. $variable has a load
of entries.
$variable = danneh blah dan etc danster;
What i want to do, without having to
Nicole Seitz wrote:
hi there!
Hello,
I've got a problem with a complex data structure and hope you can help me.
I know that I can't have a hash whose values are arrays. So I tried to
build a hash of references to arrays.
I guess I've made some mistakes .
This is what my hash
Excellent, worked!
Cheers
Dan
John W. Krahn [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Dan wrote:
Hey, I have a slight dilemma which i'm struggling to overcome. Wondering
if
anyone has any ideas on this..
I have a variable, for example's sake, say
David Eason [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
What does the error No suitable installation target for package ...
mean?
I am using ppm 3.0.1 from perl 5.8.0 build 802.
ppm describe G
Name: G
Version: 4.1
Author: Jan
Rob Dixon wrote:
Alan C. [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Rob Dixon wrote:
my $last = undef;
while ()
{
next unless defined $last;
chomp $last unless /^\./;
print $last;
} continue {
$last = $_;
}
On Sat, Jan 11, 2003 at 02:00:58PM -0800, John W. Krahn wrote:
Rob Dixon wrote:
Michael Kelly [EMAIL PROTECTED] wrote
# print out all the captured numbers
map{ print $_\n; } @numbers;
Hi Michael.
May I warn against using 'map' in a void context like this? It'll work,
sure, but
From: David Eason [EMAIL PROTECTED]
What does the error No suitable installation target for package ...
mean? I am using ppm 3.0.1 from perl 5.8.0 build 802.
It means that PPM did not find the right version of the module for
your version of Perl.
ppm describe G
Sorry I forgot to upload the
From: Yacketta, Ronald [EMAIL PROTECTED]
I am sure someone out their in Perl land can offer a better solution
to the following.
###
### slurp in all the required data for the report
###
open ($LOG,cat $g_logdir/OrderServer-*.log|)
Hi,
I have a line of text that is all uppercase and I need to change it
to titlecase. i.e. THIS IS THE LINE needs to become This Is The
Line. I can make it all lower case using tr///. I have researched in
my books and found that and the \u to for making the next character
titlecase but
I need to slice an array such that it gives me the first through the 4th to
last in a variable length array. I thought I could just do:
@comments[0..-4]
but Perl seems to choke on this. It's perfectly okay with a slice using two
negative #s:
@comments[-2..-4]
Anyone know why it doesn't
I'm trying to install the NMS FormMail program on a clients web site. I think
that I have done everything correctly but when I test the script I get the
following error message:
Application Error
An error has occurred in the program
close sendmail pipe failed, mailprog=[/usr/sbin/sendmail -oi
David Gerler wrote:
Hi,
I have a line of text that is all uppercase and I need to change it
to titlecase. i.e. THIS IS THE LINE needs to become This Is The
Line. I can make it all lower case using tr///. I have researched in
my books and found that and the \u to for making the next
perldoc -q capitalize
/R
David Gerler [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Hi,
I have a line of text that is all uppercase and I need to change it
to titlecase. i.e. THIS IS THE LINE needs to become This Is The
Line. I can make it all lower
Alan C. [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Rob Dixon wrote:
Alan C. [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Rob Dixon wrote:
my $last = undef;
while ()
{
next unless defined
Hey Jenda,
My MUA believes you used Pegasus Mail for Windows (v4.02a)
to write the following on Sunday, January 12, 2003 at 2:08:13 PM.
JK Which one would you rather do? :-)
Looking back through the thread, I think we are both arguing that the
one to use is...
my $max = (sort {$b=$a}
Sophia, et al
If you know in advance the array index then use splice.
If you know only the value you want to remove (and you like map...):
#/usr/bin/perl -w
use strict;
my %compilers = (
system1 = ['compiler_a'],
system2 = ['compiler_b', 'compiler_c','compiler_d'],
system3 = ['compiler_e'],
I have written a program in perl that collects some data and prints it to the screen
based on parameters that are given
on the command line (gee original idea for perl eh). Most of the time there are more
lines in the file being printed
than there are on my display. I would like to get it to
Moving on, same subject/problem, but slightly different scenario..
In my next variable $variable2, i have entries:
$variable2 = #ha #bad #cod #ba #dog;
Basically, i want to be able to remove #ba, without removing #ba from #bad,
so it ends up:
$variable2 = #ha #bad #cod #dog;
This also needs to
Korthrun wrote:
I have written a program in perl that collects some data and prints
it to the screen based on parameters that are given on the command
line (gee original idea for perl eh). Most of the time there are more
lines in the file being printed than there are on my display. I would
Jenda Krynicky wrote:
From: Yacketta, Ronald [EMAIL PROTECTED]
I am sure someone out their in Perl land can offer a better solution
to the following.
###
### slurp in all the required data for the report
###
open ($LOG,cat
Hello all,
I need to strip some HTML tags from a stringHowever, the complete tags are not
consistent, so I would like to remove all the text between certain strings I
specify.regardless of what is between them!
For example:
I would like to remove all the text starting with
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 13, 2003 1:25 PM
To: [EMAIL PROTECTED]
Subject: String Stripping?
Hello all,
I need to strip some HTML tags from a stringHowever,
the complete tags are not consistent, so I
Hello Jenda,
JK Why don't you open the file directly?
JK open ($LOG,$g_logdir/OrderServer-*.log)
JK or die ( Unable to open $g_logdir/OrderServer-*.log : $!);
JK or am I misunderstanding something?
I will give that a whirl in the AM, could have sworn I tried that and
Michael Kelly [EMAIL PROTECTED] wrote
On Sat, Jan 11, 2003 at 02:00:58PM -0800, John W. Krahn wrote:
Rob Dixon wrote:
Michael Kelly [EMAIL PROTECTED] wrote
# print out all the captured numbers
map{ print $_\n; } @numbers;
Hi Michael.
May I warn against using 'map' in a
Stefan Lidman [EMAIL PROTECTED] wrote:
David Gerler wrote:
Hi,
I have a line of text that is all uppercase and I need to change it
to titlecase. i.e. THIS IS THE LINE needs to become This Is The
Line. I can make it all lower case using tr///. I have researched in
my books
37 matches
Mail list logo