Hi All,
I have a checkbox in a form named form.And one submit button in one
form named form1 and another submit button in another form form 2.
Is there any value to access the check box name in one form to another form?
Regards,
Praveena
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
2007/9/3, Praveena Vittal [EMAIL PROTECTED]:
Hi All,
I have a checkbox in a form named form.And one submit button in one
form named form1 and another submit button in another form form 2.
Is there any value to access the check box name in one form to another form?
You can't submit two
Jeff Pang wrote, On 09/03/2007 12:50 PM:
2007/9/3, Praveena Vittal [EMAIL PROTECTED]:
Hi All,
I have a checkbox in a form named form.And one submit button in one
form named form1 and another submit button in another form form 2.
Is there any value to access the check box name in one form
Whilst using strict perl you cant, you can via java script and pass those
values. Its tricky to do but its possible
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 03 September 2007 09:15
To: beginners@perl.org
Subject: Re: how to get parameters from another
When we use tk, there is always the black DOS window. How can we make
it disappear?
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
2007/9/3, Praveena Vittal [EMAIL PROTECTED]:
Jeff Pang wrote, On 09/03/2007 12:50 PM:
2007/9/3, Praveena Vittal [EMAIL PROTECTED]:
Hi All,
I have a checkbox in a form named form.And one submit button in one
form named form1 and another submit button in another form form 2.
Is
Hi All,
I have tested the following script for reading the log files and write
in to the file,
#!/usr/bin/perl
use strict;
use warnings;
use File::Tail;
my $file=File::Tail-new(/log/path);
while (defined(my $line=$file-read))
{
my ($time,$lport,$ip,$stats,$rport)=split ,$line;
writedata;
sub
On 9/3/07, Somu [EMAIL PROTECTED] wrote:
When we use tk, there is always the black DOS window. How can we make
it disappear?
If you are also using Par::Packer you can pass --gui (or -g) to pp
when you build the app.
http://search.cpan.org/~smueller/PAR-Packer-0.976/lib/pp.pm
--
To
2007/9/3, sivasakthi [EMAIL PROTECTED]:
Hi All,
I have tested the following script for reading the log files and write
in to the file,
#!/usr/bin/perl
use strict;
use warnings;
use File::Tail;
my $file=File::Tail-new(/log/path);
while (defined(my $line=$file-read))
{
my
Somu [EMAIL PROTECTED] asked:
When we use tk, there is always the black DOS window. How can
we make it disappear?
If you're using ActiveState's Win32 port, you can use the
wperl.exe binary instead of plain old perl.exe.
HTH,
Thomas
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional
Hi ,
A file generated on Windows machine is used on linux m/c while scripting.
A sample line from the file is as shown:
//---^M
File name : project_name^M
.
Now in the perl script how can I remove ^M without running the command
dos2unix.
s/\r\n/\n/g
If you want to replace it with a new lime ^M is \r\n
-Original Message-
From: divya [mailto:[EMAIL PROTECTED]
Sent: 03 September 2007 12:57
To: beginners@perl.org
Subject: how to remove ^M character from every line
Hi ,
A file generated on Windows machine is used on linux
On 3 Sep 2007 at 17:26, divya wrote:
A file generated on Windows machine is used on linux m/c while scripting.
A sample line from the file is as shown:
//---^M
File name : project_name^M
.
Now in the perl script how can I remove
That will just remove all space (\s+$) at the end of the file. \r \n are
different
-Original Message-
From: Beginner [mailto:[EMAIL PROTECTED]
Sent: 03 September 2007 12:57
To: beginners@perl.org
Subject: Re: how to remove ^M character from every line
On 3 Sep 2007 at 17:26, divya
Andrew Curry wrote:
From: Beginner [mailto:[EMAIL PROTECTED]
On 3 Sep 2007 at 17:26, divya wrote:
A file generated on Windows machine is used on linux m/c while scripting.
A sample line from the file is as shown:
//---^M
File name :
On 31 ago, 22:35, [EMAIL PROTECTED] (Jm) wrote:
if you have access to the mysql client and server you don't need any
modules, just use the load data sql command with all the requisite
parameters.
if you need to make a perl script for it, just use the standard dbd
(or dbi, i forget currently
On 3 Sep 2007 at 13:38, Andrew Curry wrote:
The problem is its unclear, its always better to be clear in code. It will
also remove any formatting from the end of lines. If you wanted to be just
as crude you can use chomp.
I paritally agree that it could be un-clear. Perhaps
s/\s+$//;
Hello,
I want to give a date (the year, the day, the hour and the minute) to a
file. So, I use localtime function. But I don't understand how to use
localtime (after reading the documentation on this function). Can you
help me with this function?
Next, I want to use a shell command, so I
Those ^Ms are \015s, which is \r practically everywhere. Note
that line-oriented scripts almost work on CRLF text files on Unix
because CRLF has a trailing \n by chance. I think this is
unfortunate because instead of just breaking your program there's
the annoying situation where you
try the POSIX::strftime,this use the same datetime format as shell's
date command.
perl -e '
use POSIX qw/strftime/;
print strftime(%y%m%d %H:%M,localtime); '
070903 21:51
2007/9/3, Shams Fantar [EMAIL PROTECTED]:
Hello,
I want to give a date (the year, the day, the hour and the minute) to a
Jeff Pang wrote:
try the POSIX::strftime,this use the same datetime format as shell's
date command.
perl -e '
use POSIX qw/strftime/;
print strftime(%y%m%d %H:%M,localtime); '
070903 21:51
Okay. All right.
use POSIX qw(strftime);
my $date1 = strftime(%y/%m/%d %H:%M,localtime);
my $FILE =
2007/9/3, Shams Fantar [EMAIL PROTECTED]:
Jeff Pang wrote:
try the POSIX::strftime,this use the same datetime format as shell's
date command.
perl -e '
use POSIX qw/strftime/;
print strftime(%y%m%d %H:%M,localtime); '
070903 21:51
Okay. All right.
use POSIX qw(strftime);
my
Jeff Pang wrote:
2007/9/3, Shams Fantar [EMAIL PROTECTED]:
Jeff Pang wrote:
try the POSIX::strftime,this use the same datetime format as shell's
date command.
perl -e '
use POSIX qw/strftime/;
print strftime(%y%m%d %H:%M,localtime); '
070903 21:51
Okay. All right.
use POSIX
Hi,
I am trying to come up with a regex to squash multiple commas into
one. The line I am working on looks like this:
SPEED OF LIGHT, , LIGHT SPEED,TRAVEL,TRAVELLING, ,
DANGER,DANGEROUS,PHYSICAL, , CONCEPT,CONCEPTS, , , , , , , , , ,
There are instances of /,\s{1,},/ and /,,/
The bit
Thanks Gunnar and Mumia.
I figured out that the problem is unique to Internet Explorer. The three
other browsers I tried don't have this problem. But I can't get IE to not
cache. I've tried these:
print Cache-Control: no-cache\n;
print Pragma: no-cache\n; # for HTTP/1.0
print
Beginner wrote:
Hi,
Hello,
I am trying to come up with a regex to squash multiple commas into
one. The line I am working on looks like this:
SPEED OF LIGHT, , LIGHT SPEED,TRAVEL,TRAVELLING, ,
DANGER,DANGEROUS,PHYSICAL, , CONCEPT,CONCEPTS, , , , , , , , , ,
There are instances of
Christ That's certainly 1 way ;)
-Original Message-
From: John W. Krahn [mailto:[EMAIL PROTECTED]
Sent: 03 September 2007 16:11
To: Perl beginners
Subject: Re: Regex help
Beginner wrote:
Hi,
Hello,
I am trying to come up with a regex to squash multiple commas into
one. The line I
Think
s/(\,+\s*)+/,/g;
Should work
It produces
SPEED OF LIGHT,LIGHT
SPEED,TRAVEL,TRAVELLING,DANGER,DANGEROUS,PHYSICAL,CONCEPT,CONCEPTS
If that's what you want.
-Original Message-
From: Andrew Curry
Sent: 03 September 2007 16:14
To: 'John W. Krahn'; Perl beginners
Subject: RE: Regex
On 3 Sep 2007 at 16:15, Andrew Curry wrote:
Think
s/(\,+\s*)+/,/g;
Should work
It produces
SPEED OF LIGHT,LIGHT
SPEED,TRAVEL,TRAVELLING,DANGER,DANGEROUS,PHYSICAL,CONCEPT,CONCEPTS
If that's what you want.
Exactly what I want. Thanx,
Dp.
--
To unsubscribe, e-mail: [EMAIL
On 9/3/07, Carl Miller [EMAIL PROTECTED] wrote:
I figured out that the problem is unique to Internet Explorer. The three
other browsers I tried don't have this problem. But I can't get IE to not
cache.
Can anyone give some insight into where the problem might be?
It's in Internet Explorer,
On 3 Sep 2007 at 16:12, Andrew Curry wrote:
$ perl -le'
$_ = q[SPEED OF LIGHT, , LIGHT SPEED,TRAVEL,TRAVELLING, ,
DANGER,DANGEROUS,PHYSICAL, , CONCEPT,CONCEPTS, , , , , , , , , , ];
print; s/,\s*(?=,)//g; print; '
SPEED OF LIGHT, , LIGHT SPEED,TRAVEL,TRAVELLING, ,
Beginner wrote:
On 3 Sep 2007 at 16:12, Andrew Curry wrote:
Please do not attribute to Andrew Curry a post that was actually submitted by
me (see my name at the end there.) TIA
$ perl -le'
$_ = q[SPEED OF LIGHT, , LIGHT SPEED,TRAVEL,TRAVELLING, ,
DANGER,DANGEROUS,PHYSICAL, ,
Beginner wrote:
I am trying to come up with a regex to squash multiple commas into
one. The line I am working on looks like this:
SPEED OF LIGHT, , LIGHT SPEED,TRAVEL,TRAVELLING, ,
DANGER,DANGEROUS,PHYSICAL, , CONCEPT,CONCEPTS, , , , , , , , , ,
There are instances of /,\s{1,},/ and
Andrew Curry wrote:
Think
s/(\,+\s*)+/,/g;
Commas are not special in a regular expression so there is no need to escape
them. You are using capturing parentheses but are not using the string
captured in $1, better to use non-capturing parentheses.
s/(?:,+\s*)+/,/g;
A modified pattern
[ Please do not top-post. TIA ]
[EMAIL PROTECTED] wrote:
Hi
Hello,
Unless Perl is the only tool available to you in your toolbox and if
you're running Linux or similar consider the tr -s command in a
shell.
Perl also has that:
tr/,//s;
perldoc perlop
However if you are strictly
On 09/03/2007 10:06 AM, Carl Miller wrote:
Thanks Gunnar and Mumia.
I figured out that the problem is unique to Internet Explorer. The three
other browsers I tried don't have this problem. But I can't get IE to not
cache. I've tried these:
print Cache-Control: no-cache\n;
print
Hi
Unless Perl is the only tool available to you in your toolbox and if you're
running Linux or similar consider the tr -s command in a shell. However if
you are
strictly limited to Perl then this stand regex works:-
echo ,|perl -ane 's/,*/,/;print'
Try it by cutting and pasting it.
No
On 9/3/07, Shams Fantar [EMAIL PROTECTED] wrote:
Hello,
I want to give a date (the year, the day, the hour and the minute) to a
file. So, I use localtime function. But I don't understand how to use
localtime (after reading the documentation on this function). Can you
help me with this
Adriano Ferreira wrote:
On 9/3/07, Shams Fantar [EMAIL PROTECTED] wrote:
Hello,
I want to give a date (the year, the day, the hour and the minute) to a
file. So, I use localtime function. But I don't understand how to use
localtime (after reading the documentation on this function). Can you
divya wrote:
A file generated on Windows machine is used on linux m/c while scripting.
A sample line from the file is as shown:
//---^M
File name : project_name^M
.
Now in the perl script how can I remove ^M without running the command
Hi !
I have a problem at which I have no solution.
Here is the algorithm :
If there is a file in this directory which is old likewise of 10 days,
to delete it or else, do nothing.
Do you have ideas to say If there is a file which is old likewise of 10
days in perl?
Best regards,
--
On 9/3/07, Shams Fantar [EMAIL PROTECTED] wrote:
Do you have ideas to say If there is a file which is old likewise of 10
days in perl?
There are three timestamps that can mean the age of a file: the mtime,
atime, and ctime. If you want to know how old the data in the file is,
that's the mtime,
Shams Fantar wrote:
Here is the algorithm :
If there is a file in this directory which is old likewise of 10 days,
to delete it or else, do nothing.
Do you have ideas to say If there is a file which is old likewise of 10
days in perl?
opendir my $d, $dir or die $!;
my @oldfiles =
On Mon, 2007-09-03 at 21:56 +0200, Shams Fantar wrote:
Hi !
I have a problem at which I have no solution.
Here is the algorithm :
If there is a file in this directory which is old likewise of 10 days,
to delete it or else, do nothing.
Do you have ideas to say If there is a file
On 9/3/07, Ken Foskey [EMAIL PROTECTED] wrote:
On Mon, 2007-09-03 at 21:56 +0200, Shams Fantar wrote:
Hi !
I have a problem at which I have no solution.
Here is the algorithm :
If there is a file in this directory which is old likewise of 10 days,
to delete it or else, do nothing.
Carl Miller schreef:
The other website would call the perl script in an img tag, like so:
img src=http://www.my_site.com/cgi-bin/random_banner.cgi;
width=468 height=60
I've tried several perl scripts that basically work, but the problem
is always the same with all of them: the browser
Hello,What're the meanings of this routine and why people need it?Thanks.sub
make_accessor {my($package, $name) = @_;no strict qw(refs);my $code =
EOT;*{$package\\::$name} = sub {my(\$self, \$value) = [EMAIL
PROTECTED];if(defined \$value) {\$self-{$name} = \$value;}if(exists
\$self-{$name})
sorry send it again with plain text.
sub make_accessor {
my($package, $name) = @_;
no strict qw(refs);
my $code = EOT;
*{$package\::$name} = sub {
my($self, $value) = @_;
if(defined $value) {
$self-{$name} = $value;
}
When destructing a variable,one can say `$var = ''` or `$var =
undef`,which way is good?
like two cases follow,
sub DESTROY
{
my $self = shift;
$self-{array} = undef;
}
or
sub DESTROY
{
my $self = shift;
$self-{array} = '';
}
Given $self-{array} is a large array's reference.
lists == lists user [EMAIL PROTECTED] writes:
lists When destructing a variable,one can say `$var = ''` or `$var =
lists undef`,which way is good?
lists like two cases follow,
lists sub DESTROY
lists {
lists my $self = shift;
lists $self-{array} = undef;
lists }
lists or
lists sub
50 matches
Mail list logo