I have like 20 variable coming from a form, using CGI.pm in my script.
I am at a loss as how to get $ENV{'Content_lenght'} for all of those
collectively. Is there anything in CGI.pm for it?. I am trying to count every
keystroke that user inputs to form.
Thanks,
Sara.
Hi!
I'm have a big problem. I make a module(pm) and now i
want compile this module. I tried use the perlcc but i
receive the msg that the module can't be compiled
because have shared libs.
However i found a module, PAR(Perl Archive Toolkit)
which can compile my module. Then, i was to install
Content length includes all the content, including names of form
parameters, etc. If you want to count the keystrokes for a form, you
could just run through the form parameters and get the length of each
value (assuming they are all text fields). Check out these two links
to the CGI.pm
Hey Augusto,
We has this problem just yesterday with Perl2exe. It was an extra
character on Line 1. Not sure what you are using and an IDE but I would
make sure it is not added extra characters that you do don't know about.
Remove the first line altogether and retype it.
Try Notepad or
Hi all,
My friend is making website in PHP, but my scripts are in Perl, for
example user write some text, and I want for example print it
uppercase (I know, bad example, but I want/have to do it - something
different and more complex - in my case via Perl).
So I'm thinking how to do it best.
Why the length is not coming out? Any ideas?
#
my @aho = (fgfgfgf, fgfgfgfgf, fgfgfgfg);
my $length += length($_) for @aho;
print Content-type: text/plain\n\n;
print $length;
#
Thanks,
Sara.
Sara wrote:
Why the length is not coming out? Any ideas?
#
my @aho = (fgfgfgf, fgfgfgfgf, fgfgfgfg);
my $length += length($_) for @aho;
A perl gotcha. The 'for' modifier creates a loop, and the 'my' is scoped
to the body of that loop (I
4:19pm, Ing. Branislav Gerzo wrote:
Hi all,
My friend is making website in PHP, but my scripts are in Perl, for
example user write some text, and I want for example print it
uppercase (I know, bad example, but I want/have to do it - something
different and more complex - in my case via Perl).
So
Tommy Nordgren [TN], on Thursday, February 3, 2005 at 04:25 (+0100)
typed the following:
TN I have the need to generate and match a large number (Typically 50 -
TN 200) of regular expressions.
TN Each regular expression should be written in a subset of the perl
TN regular expression syntax, or
okay this may seem like a simple problem but here it goes:
when running the the script below from the unix (mac osx) command line
the survey.txt file is created and this a test!!! is written to the
file. But when running it from a browser the file is Not created and
Browser test is displayed in
That is because you are *not* printing Browser Test to the OUTFILE handle.
open(OUTFILE, survey.txt);
print OUTFILE this is a test!!!\n;
print OUTFILE htmlBrowser test/html\n;
close(OUTFILE);
-Original Message-
From: Elliot Holden [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 03,
Elliot Holden [EH], on Thursday, February 03, 2005 at 01:24 (-0500)
wrote:
EH open(OUTFILE, survey.txt);
EH print OUTFILE this is a test!!!\n;
EH close(OUTFILE);
EH print htmlBrowser test/html\n;
you should always use open with die. For example:
open(OUTFILE, survey.txt) or die Can't open $!\n;
Elliot Holden [EMAIL PROTECTED] asked:
okay this may seem like a simple problem but here it goes:
[...]
open(OUTFILE, survey.txt);
[...]
Your web server may not have permission to create
the file in question. Always check return codes!
open(OUTFILE, survey.txt) or die Could not open file: $!;
Feb 3, 2005 kl. 4:25 AM skrev Tommy Nordgren:
I have the need to generate and match a large number (Typically 50 -
200) of regular expressions.
Each regular expression should be written in a subset of the perl
regular expression syntax, or another suitable syntax. I have not
committed to a
Michael == Michael Kraus [EMAIL PROTECTED] writes:
Michael The package names are actually section, dbh_section and checkout
(rather
Michael than A,B and C respectively).
Lowercase names are also reserved for pragmas. You should choose
names that begin with uppercase letters, and have some
Is there any way in perl I can modify the permission of a directory using perl
scripts
Anish
Feb 3, 2005 kl. 12:32 PM skrev Anish Kumar K.:
Is there any way in perl I can modify the permission of a directory
using perl scripts
Anish
$dir = shift @ARGV;
$perms = ?? #Whatever you wan't
system('chmod', $perms,$dir) if -d $dir;
Home is not where you are born, but where your heart finds
Anish Kumar K. [EMAIL PROTECTED] asked:
Is there any way in perl I can modify the permission of a
directory using perl scripts
Of course. Check out the builtins chmod and chown.
HTH,
Thomas
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
- Original Message -
From: Anish Kumar K. [EMAIL PROTECTED]
To: Tommy Nordgren [EMAIL PROTECTED]
Sent: Thursday, February 03, 2005 6:13 PM
Subject: Re: Modifying directory permission
Hi this is through CGI.In CGI it is not working...
I tried cp also in normal mode.. that is
On 3 Feb 2005, at 06:24, Elliot Holden wrote:
okay this may seem like a simple problem but here it goes:
when running the the script below from the unix (mac osx) command line
the survey.txt file is created and this a test!!! is written to
the file. But when running it from a browser the file is
On Wed, 02 Feb 2005 20:37:54 +, mike [EMAIL PROTECTED] wrote:
No the problem was that this ( with the quote in the right place) was
giving me what I didnt want.
this is the code
@value=param();
shift (@value);
shift (@value);
pop (@value);
print @value;
foreach $value (@value){
On Thu, 3 Feb 2005 02:09:53 +0100, Babale Fongo [EMAIL PROTECTED] wrote:
It is a bit weird, but I could workaround it by first joining the value,
and splitting it thereafter:
@splitted = split /\s+/, join , @found;
Thanks anyway...
||-Original Message-
||From: Babale Fongo
On Thu, 3 Feb 2005 12:11:14 +0100, Tommy Nordgren
[EMAIL PROTECTED] wrote:
My problem is to generate from specs the lexical analyzer and parser
for the semantic
actions, which I wan't to allow writing in any object oriented language.
The language to use will be specified in the input
Hello to all
I want to replace the with the amp;
I use the command s/\/\amp;/; with no luck
Does anybody know what am i missing here?
Elliot Holden wrote:
okay this may seem like a simple problem but here it goes:
when running the the script below from the unix (mac osx) command line
the survey.txt file is created and this a test!!! is written to the
file. But when running it from a browser the file is Not created and
Browser
Anish Kumar K. wrote:
Is there any way in perl I can modify the permission of a directory using perl scripts
perldoc perlfunc
[snip]
Functions for filehandles, files, or directories
^^^
-X, chdir, chmod, chown, chroot, fcntl,
Hello to all
I want to replace the special char with the amp;
I am using that command s/\/\amp;/; with no luck.
Do you know what am i missing?
Thanks in advance
Try this, and remember - with XML there are more than one you have to
change:
sub xc {
#returns text free of XML baddies - xc = xml clean
my $data = $_[0];
$data =~ s//amp;/g;
$data =~ s//lt;/g;
$data =~ s//gt;/g;
$data =~ s/'/apos;/g;
$data =~
From: Anish Kumar K. [EMAIL PROTECTED]
Is there any way in perl I can modify the permission of a directory
using perl scripts
It never ceases to amaze me how often people forget to specify their
operating system when asking apparently OS specific questions ...
Jenda
= [EMAIL PROTECTED]
I have the following code snippet, designed to let my script accept
the ubiquitous unambiguous abbreviations in a configuration file.
The ultimate goal, for those who are interested, is to take the
abbreviated entries and generate a cononical bibTeX database file.
this is what I have so far to
Hi,
I'm looking for a regexp that will match two
expressions. Each line of the file I'm reading
contains different months and years. I'm only after
those lines with particular year and month. All those
lines with january and 2005 for example. Any idea?
Thanks!
here's a portion of the file.
Wed
G'day...
Thanks... :)
So, I should have names like:
Wild::Section
Wild::Section::DBH
Wild::CheckOut
For my classes, instead of the ones listed previously...
Thanks... (It's easier being corrected by the person whom you
originally learnt Perl from... Even if they don't realise it.)
Regards,
You mean like this? I'm not 100% sure what you're asking.
##
use strict;
use warnings;
open(INFILE,myfile.txt) || die Couldn't open 'myfile.txt' for
reading!\n;
my @LinesIWantToKeep;
while(INFILE){
if($_ =~ /Jan 12/){
push
--- Tim Johnson [EMAIL PROTECTED] wrote:
You mean like this? I'm not 100% sure what you're
asking.
I guess not. For example,
Wed Jan 12 03:50:18 PHT 2005 updating...
Sun Jan 9 10:00:10 PHT 2005 not updating
Fri Jan 7 09:40:14 PHT 2005 down
Sat Jan 31 19:18:53 PHT 2004 down
Sat Jan 31
Oh, ok. So you mean like...
if($_ =~ /\bJan\b.*\bDec\b/){
print $_;
}
?
-Original Message-
From: Harold Castro [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 03, 2005 5:02 PM
To: Tim Johnson; beginners@perl.org
Subject: RE: Is there a regexp that will match two or more
Harold Castro [EMAIL PROTECTED] wrote:
: --- Tim Johnson [EMAIL PROTECTED] wrote:
:
: :
: :
: : You mean like this? I'm not 100% sure what you're
: : asking.
: I guess not. For example,
:
: Wed Jan 12 03:50:18 PHT 2005 updating...
: Sun Jan 9 10:00:10 PHT 2005 not updating
: Fri Jan 7 09:40:14
36 matches
Mail list logo