You might consider using Regexp::Common::net. It provides a convenient set
of functions for matching IP v4, v6 and mac addresses.
https://metacpan.org/pod/Regexp::Common::net
On Fri, 25 Oct 2019 at 19:43, John W. Krahn wrote:
> On 2019-10-25 3:23 a.m., Maggie Q Roth wrote:
> > Hello
>
> Hell
On 2019-10-25 3:23 a.m., Maggie Q Roth wrote:
Hello
Hello.
There are two primary types of lines in the log:
What are those two types? How do you define them?
60.191.38.xx/
42.120.161.xx /archives/1005
From my point of view those two lines have two fields, the first loo
/(?[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})\s+(?\/.*)/
To avoid the "leaning toothpick" problem, Perl lets use different match
delimiters, so the above is the same as:
m#(?[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})\s+(?/.*)#
I assume you want to capture the IP and the path, right?
if
That is a backslash followed by a forward slash. The backslash tells the
regex parser to treat the next character as a literal character. Useful for
matching periods, question marks, brackets, etc.
A period matches any character once and an asterisk matches the previous
character any number of time
my $n = '[0-9]{1,3}';
if ( =~ ( m[ (?:$n\.){3} $n \s+ \S+ ]x )
{
# match
}
On Fri, Oct 25, 2019 at 3:37 AM Maggie Q Roth wrote:
> what's V.*?
>
> Maggie
>
> On Fri, Oct 25, 2019 at 6:28 PM Илья Рассадин wrote:
>
>> For example, this regex
>>
>> /(?[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,
what's V.*?
Maggie
On Fri, Oct 25, 2019 at 6:28 PM Илья Рассадин wrote:
> For example, this regex
>
> /(?[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})\s+(?\/.*)/
>
> On 25.10.2019 13:23, Maggie Q Roth wrote:
> > Hello
> >
> > There are two primary types of lines in the log:
> >
> > 60.191.38.
For example, this regex
/(?[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})\s+(?\/.*)/
On 25.10.2019 13:23, Maggie Q Roth wrote:
Hello
There are two primary types of lines in the log:
60.191.38.xx /
42.120.161.xx /archives/1005
I know how to write regex to match each line, but do
Hello
There are two primary types of lines in the log:
60.191.38.xx/
42.120.161.xx /archives/1005
I know how to write regex to match each line, but don't get the good result
with one regex to match both lines.
Can you help?
Thanks,
Maggie
Hi,
If you have time, I will be very appreciate you helping transform below code.
I have just uploaded the whole files into the following link:
https://docs.google.com/open?id=0B93SVRfpVVg3QzdsYUNkOU5SSHEtOTlqVm54WUdjdw
can run with perl extractbib.pl sample.tex
#!/usr/bin/env perl
use strict
On Wednesday 18 May 2011 12:25:52 ind...@students.itb.ac.id wrote:
> Dear all,
>
> I try to run this script to process my radar data, the script build by
> someone, I have asked him, but his advice can not help. This error message
> : ARGV error
> firstradar velx vely
>
> This is the Perl code:
>
> "S" == Saran writes:
S> Try something like
S> if(scalar(@ARGV) != 3) {
there is no need for scalar there. the != op provides a scalar context
so @ARGV will return its count.
uri
--
Uri Guttman -- u...@stemsystems.com http://www.sysarch.com --
- Perl Code Revie
Try something like
if(scalar(@ARGV) != 3) {
The above statement will execute if there is less than or greater than
three command line arguments..
~ Saran
On May 18, 2:37 pm, benignb...@gmail.com (Balachandran Sivakumar)
wrote:
> On Wed, May 18, 2011 at 2:55 PM, wrote:
> > ARGV error
> > first
On Wed, May 18, 2011 at 2:55 PM, wrote:
> ARGV error
> firstradar velx vely
>
>
> if(@ARGV != 3){
> print "ARGV error \n";
> print "firstradar velx vely \n";
> exit(1);
> }
>From what I see, this script expects command line arguments
and expects 3 arguments. So, you should run it someth
Dear all,
I try to run this script to process my radar data, the script build by someone,
I have asked him, but his advice can not help. This error message :
ARGV error
firstradar velx vely
This is the Perl code:
#! /usr/bin/perl
$UNFOLD = 0; #1=UNFOLD^[$B%G!<%?$r;HMQ^[(B
0=^[$B@8^[(Bvolu
On 12/05/2011 10:23, Nathalie Conte wrote:
HI,
I have this file format
chr start end strand
x 12 24 1
x 24 48 1
1 100 124 -1
1 124 148 -1
Basically I would like to create a new file by grouping the start of the
first line (12) with the end of the second line (48) and so on
the output should lo
On Thu, May 12, 2011 at 11:23 AM, Nathalie Conte wrote:
HI,
I have this file format
chrstartendstrand
x 12241
x24481
1100124-1
1124148-1
Basically I would like to create a new file by grouping the start of the
first line (12) with the
On Thu, May 12, 2011 at 10:23:29AM +0100, Nathalie Conte wrote:
> I have this file format
> chrstartendstrand
> x 12241
> I have this script to split and iterate over each line, but I don't
> know how to group 2 lines together, and take the start of the firt line
> and
On Thu, May 12, 2011 at 6:23 AM, Nathalie Conte wrote:
> I have this script to split and iterate over each line, but I don't know
> how to group 2 lines together, and take the start of the firt line and the
> end on the second line? could you please advise? thanks
>
>
You have a couple of option
Nathalie Conte wrote:
HI,
Hello,
I have this file format
chr start end strand
x 12 24 1
x 24 48 1
1 100 124 -1
1 124 148 -1
Basically I would like to create a new file by grouping the start of the
first line (12) with the end of the second line (48) and so on
the output should look like thi
You are almost there :-)
my ($helper1, $helper2);
my $counter = 1;
foreach my $line(@list){
chomp $line;
my @coordinates = split(/' '/, $region);
my $chromosome = $coordinates[0];
my $start = $coordinates[1];
my $end = $coordinates[2];
my $strand = $coordinates[3
HI,
I have this file format
chrstartendstrand
x 12241
x24481
1100124-1
1124148-1
Basically I would like to create a new file by grouping the start of the
first line (12) with the end of the second line (48) and so on
the output shoul
Hi Yang,
> sub ok ($;$) { } and sub is ($$;$) { }
Those are subroutines with prototypes. `sub NAME(PROTO)`
`sub ok ($;$)`
Requires one mandatory argument and an optional one. They are
separated by a semi-colon in the prototype definition. The arguments
will be considered in scalar context (due
- Original Message -
From: "jyang"
Hi all :
I watch a function that is package "Test::More " ,which is that segment
such as :
sub ok ($;$) { } and sub is ($$;$) { }
please tell me what means "($;$)" , or give me some reference manual let
me know it; thank you!
http://www.perlmon
From: "jyang"
Hi all :
I watch a function that is package "Test::More " ,which is that segment
such as :
sub ok ($;$) { } and sub is ($$;$) { }
please tell me what means "($;$)" , or give me some reference manual let
me know it; thank you!
Read:
perldoc perlsub
If you don't really n
Hi,
On Wednesday 05 Jan 2011 09:02:29 jyang wrote:
> Hi all :
>
> I watch a function that is package "Test::More " ,which is that segment
> such as :
> sub ok ($;$) { } and sub is ($$;$) { }
>
> please tell me what means "($;$)" , or give me some reference manual let
> me know it; thank you!
Hi all :
I watch a function that is package "Test::More " ,which is that segment
such as :
sub ok ($;$) { } and sub is ($$;$) { }
please tell me what means "($;$)" , or give me some reference manual let me
know it; thank you!
2011-01-05
Best Regards!
-Yang
> "Matthew" == Matthew Young writes:
Matthew> What are closures? How are they used? When should they be used? Where
Matthew> can I learn more about them?
If you can borrow (or buy :) a copy of Intermediate Perl, I have an
entire section on closures in there.
--
Randal L. Schwartz - Stonehen
Matthew Young wrote:
I often read about closures being one of those 'end all beat all'
programming techniques reserved for the most sophisticated and
advanced gurus out there. Naturally, I want to learn how to use them,
and use them effectively - I know perl supports them! I know its a
sort of fu
Hi Matthew,
On Friday 12 November 2010 19:26:34 Matthew Young wrote:
> I often read about closures being one of those 'end all beat all'
> programming techniques reserved for the most sophisticated and
> advanced gurus out there. Naturally, I want to learn how to use them,
> and use them effective
I often read about closures being one of those 'end all beat all'
programming techniques reserved for the most sophisticated and
advanced gurus out there. Naturally, I want to learn how to use them,
and use them effectively - I know perl supports them! I know its a
sort of functional programming co
>>
>> What does it say in a hex editor?
>>
>
>
> # hexdump Test.pl
> 000
> *
> 0001090
> 0001094
I would take a guess and say don't waste anymore time on it. Put your
energies in rewriting the program
--
Owen
--
To unsubscribe, e
>
> What does it say in a hex editor?
>
# hexdump Test.pl
000
*
0001090
0001094
Cheers,
Parag
>>
>> I think it's from UTF-16 to UTF-8.
>>
>>
>
> That doesn't seem to work.
>
> When I try to view my roasted file through 'less' command I get
> following
> output:
>
> # less Test.pl
> *"Test.pl" may be a binary file. See it anyway? *
>
> Is there a way I can convert this binary file to its i
>
> I think it's from UTF-16 to UTF-8.
>
>
That doesn't seem to work.
When I try to view my roasted file through 'less' command I get following
output:
# less Test.pl
*"Test.pl" may be a binary file. See it anyway? *
Is there a way I can convert this binary file to its initial readable state.
'iconv'
> > with a Perl script which will help me recover my Perl script.
>
> I think it's from UTF-16 to UTF-8.
>
Oh! And next time, you should make use of a version control system preferably
with a remote and reliable physical server:
http://better-scm.berlios.
On Friday 25 Dec 2009 09:07:53 Parag Kalra wrote:
> Can anyone please let me know how to use 'iconv' command with Perl script.
>
> I mean what should be my input and output file format while using 'iconv'
> with a Perl script which will help me recover my Perl scri
> "Parag" == Parag Kalra writes:
Parag> I was coding my Perl script in Notepad++ editor and it was on verge of
Parag> completion.
Parag> All of a sudden my machine rebooted. And after that I found all my data
Parag> lost. It is containing series of 'NUL' characters.
Welcome to Windows. Per
Can anyone please let me know how to use 'iconv' command with Perl script.
I mean what should be my input and output file format while using 'iconv'
with a Perl script which will help me recover my Perl script.
Hey BTW Merry Christmas to all. :)
Cheers,
Parag
On Fri, D
Hello All,
I was coding my Perl script in Notepad++ editor and it was on verge of
completion.
All of a sudden my machine rebooted. And after that I found all my data
lost. It is containing series of 'NUL' characters.
However size of the Perl script is same as it was earlier.
Plea
> "SHC" == Shawn H Corey writes:
SHC> New-style Perl objects are written in Moose
don't claim moose is the only new style objects. nor are they the
ultimate as they have their issues too. plain old hash objects are fine
for most common classes and better in many cases too than complex
thi
From: 120
> I've looked at this:
>
> sub encrypt {
> my $self = shift;
> my $xx = $$self;
> #.. cut stuff I do understand
>
> return $self->SUPER::encrypt();
> }
>
> Could someone help me with the Perl to English here?
> I get tha
120 wrote:
> On Sat, 2009-12-05 at 08:45 -0500, Someone Something wrote:
>> SUPER is a class that controls the superclass of the current class.
>> Look here: http://search.cpan.org/~chromatic/SUPER-1.17/lib/SUPER.pm
>>
>> So, what that means is, run the encrypt method/subroutine/function of
>> the
On Sat, 2009-12-05 at 08:45 -0500, Someone Something wrote:
> SUPER is a class that controls the superclass of the current class.
> Look here: http://search.cpan.org/~chromatic/SUPER-1.17/lib/SUPER.pm
>
> So, what that means is, run the encrypt method/subroutine/function of
> the superclass of the
shift;
> my $xx = $$self;
> #.. cut stuff I do understand
>
> return $self->SUPER::encrypt();
> }
>
> Could someone help me with the Perl to English here?
> I get that $self is shifting the arguement.
> I think I get that $xx is a reference to $self?
> I
#.. cut stuff I do understand
return $self->SUPER::encrypt();
}
Could someone help me with the Perl to English here?
I get that $self is shifting the arguement.
I think I get that $xx is a reference to $self?
I don't get at all: return $self->SUPER::encrypt();
Is this assignin
-邮件原件-
发件人: Chris Charley [mailto:char...@pulsenet.com]
发送时间: 2009年11月19日 5:21
收件人: beginners@perl.org
主题: Re: mkdir in the mounted partition,please help me,thanks
- Original Message -
From: ""Chris Charley""
Newsgroups: perl.beginners
To:
Sent: Wednesda
/dev/sdd1 1.7T 639G 1004G 39% /data6
/dev/sdf1 1.7T 1.1T 578G 65% /data8
-邮件原件-
发件人: John W. Krahn [mailto:jwkr...@shaw.ca]
发送时间: 2009年11月18日 14:12
收件人: Perl Beginners
主题: Re: mkdir in the mounted partition£¬please help me£¬thanks
gaochong wrote:
> #!/us
gaochong wrote:
#!/usr/bin/perl -w
#Auther:gaochong
use strict;
my @list = (3 .. 9);
my @FA=("FA0001".."FA2000");
sub mk_fa {
my ($f) = @_;
foreach my $p (@list) {
mkdir "/data$p/NRU/$f",0755 or warn "mkdir /data$p/NRU/$f
err:$!";
symlink
I did not receive err msg .
-邮件原件-
发件人: Dermot [mailto:paik...@googlemail.com]
发送时间: 2009年11月17日 20:16
收件人: beginners@perl.org
主题: Re: 答复: mkdir in the mounted partition,please help me,thanks
2009/11/17 gaochong :
> but I have uses perl -w。
> any other problem ?
Did you recei
2009/11/17 gaochong :
> but I have uses perl -w。
> any other problem ?
Did you receive and error message?
Dp.
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/
but I have uses perl -w。
any other problem ?
-邮件原件-
发件人: Dermot [mailto:paik...@googlemail.com]
发送时间: 2009年11月17日 19:53
收件人: beginners@perl.org
主题: Re: mkdir in the mounted partition,please help me,thanks
2009/11/17 gaochong :
> #!/usr/bin/perl -w
>
>
>
> #Auther:gaoch
2009/11/17 gaochong :
> #!/usr/bin/perl -w
>
>
>
> #Auther:gaochong
>
>
>
> use strict;
>
>
>
> my @list = (3 .. 9);
>
> my @FA=("FA0001".."FA2000");
>
> sub mk_fa {
>
> my ($f) = @_;
>
> foreach my $p (@list) {
>
> mkdir "/data$p/NRU/$f",0755 or warn "mkdir /da
On Sat, Jul 25, 2009 at 05:48, Shawn H. Corey wrote:
> Umar Draz wrote:
>>
>> As you can see its not works because there is no space after the word is
>> So would you please help me how to solve this.
>>
>
> Change the word boundary, \b, to a not-digit, \D.
snip
Umar Draz wrote:
As you can see its not works because there is no space after the word is So
would you please help me how to solve this.
Change the word boundary, \b, to a not-digit, \D.
--
Just my 0.0002 million dollars worth,
Shawn
Programming is as much about organization and
Mobile No. is " . $1 . "\n";
> }
> As you can see its not works because there is no space after the word is
> So would you please help me what kind of change is required in above
> regular expression.
#!/usr/bin/perl
use warnings;
use strict;
my $str = "&quo
}
Here is the output of while
Your Mobile No. is 0300-4459899
Your Mobile No. is 0356-4094030
Your Mobile No. is 03226789871
its Work almost fine but one mobile no. is missed and that is My Office Cell
is0300-5009228
As you can see its not works because there is no space after the word i
re is the output of while
Your Mobile No. is 0300-4459899Your Mobile No. is 0356-4094030Your Mobile No.
is 03226789871
its Work fine but one mobile no. is missed and that is My Office Cell
is0300-5009228
As you can see its not works because there is no space after the word is So
would you please
Christer Ekholm wrote:
> Steve Bertrand writes:
>
>> Umar Draz wrote:
>>> Hello Steve
>>>
>>> Thanks for your help.
>>>
>>> Would you please help me one thing more
>>>
>>> I have string e.g
>>>
>>> $s
Steve Bertrand writes:
> Umar Draz wrote:
>> Hello Steve
>>
>> Thanks for your help.
>>
>> Would you please help me one thing more
>>
>> I have string e.g
>>
>> $str = "Hello this is my string (1020p0404), this string is not com
Umar Draz wrote:
> Hello Steve
>
> Thanks for your help.
>
> Would you please help me one thing more
>
> I have string e.g
>
> $str = "Hello this is my string (1020p0404), this string is not complete
> (1 034 400 3). now the string complte";
>
&g
o handle spaces e.g
>
> $str
> = "This is my string my mobile number is 042-6715171 0 30 0- 4 4 5 9 8
> 9 9, 0 42-84 94 94 9, 0 4 1 - 85 80 8 8 0 now the string is complete"
> while($line =~ /(([0-9]{3,4}[-]?)?[0-9]{7})/g){
>
> $tel = $1
>
> }
>
>
&
Umar Draz wrote:
> Dear User!
>
> I want to get all telephone and mobile number from a string and save into a
> variable. Here is my example what i am doing.
>
> #!/usr/bin/perl
>
> $str = "This is my string my mobile number is 0300-4459899, 042-8494949
> 041-8580880 now the string is complete
1 - 85 80 8 8 0 now the string is complete"
while($line =~ /(([0-9]{3,4}[-]?)?[0-9]{7})/g){
$tel = $1
}
now this time only (042-6715171) are saved in $tel variable.
Would you please help me to solve this issue.
Regards,
Umar
Gowri Chandra Sekhar Barla, TLS, Chennai wrote:
>
> Please help me in rearranging line numbers in a file
>
> Example"
>
> File.txt
> 1 ghghjghjg
> 2 1hjkhkjh
> 3
> 4 .macro TTT offset
> 5 TTT 200
> 6 TTT 300
> 7 fghfghf
> 8 hjhjkhjkh
>
Is this your homework???
On Fri, Nov 21, 2008 at 5:19 PM, Gowri Chandra Sekhar Barla, TLS, Chennai <
[EMAIL PROTECTED]> wrote:
>
> Hi all
>
> Please help me in rearranging line numbers in a file
>
> Example"
>
> File.txt
> 1 ghghjghjg
> 2 1hjkhkjh
&g
Hi all
Please help me in rearranging line numbers in a file
Example"
File.txt
1 ghghjghjg
2 1hjkhkjh
3
4 .macro TTT offset
5 TTT 200
6 TTT 300
7 fghfghf
8 hjhjkhjkh
9 kgghjgg
Output should be
File.txt
1 ghghjghjg
2 1hjkhkjh
3
.macro TTT offset
TTT 200
TTT 300
4 fghf
Chas. Owens wrote:
On Tue, Oct 14, 2008 at 02:15, Richard Lee <[EMAIL PROTECTED]> wrote:
below sub works fine except the line where key is default.
Instead of printing out PCMU only once, it's printing it out 40 times
randomly..
Trying to figure out what I did wrong.
snip
I found your
Chas. Owens wrote:
On Tue, Oct 14, 2008 at 02:15, Richard Lee <[EMAIL PROTECTED]> wrote:
below sub works fine except the line where key is default.
Instead of printing out PCMU only once, it's printing it out 40 times
randomly..
Trying to figure out what I did wrong.
snip
I found your
On Tue, Oct 14, 2008 at 02:15, Richard Lee <[EMAIL PROTECTED]> wrote:
> below sub works fine except the line where key is default.
> Instead of printing out PCMU only once, it's printing it out 40 times
> randomly..
> Trying to figure out what I did wrong.
snip
I found your code to be very odd. Y
John, I think this is now fixed.
Still looking to make sure its covering all basis..
sub codec_list {
#my @codec_d = qw/0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
19 20 21 22 23 24 25 26 27
# 28 29 30 31 32 33 34 35--71 72--76 77--95 96--127/;
my @codec_d = qw
John W. Krahn wrote:
Richard Lee wrote:
below sub works fine except the line where key is default.
Instead of printing out PCMU only once, it's printing it out 40 times
randomly..
Trying to figure out what I did wrong.
Please leave me a feedback.
thank you.
156 time(s) Codec(s) : unassign
Richard Lee wrote:
below sub works fine except the line where key is default.
Instead of printing out PCMU only once, it's printing it out 40 times
randomly..
Trying to figure out what I did wrong.
Please leave me a feedback.
thank you.
156 time(s) Codec(s) : unassigned_38
185 time(s) Cod
below sub works fine except the line where key is default.
Instead of printing out PCMU only once, it's printing it out 40 times
randomly..
Trying to figure out what I did wrong.
Please leave me a feedback.
thank you.
156 time(s) Codec(s) : unassigned_38
185 time(s) Codec(s) : G729
Thanks Chas Owens for your detailed explanation.
It helped me a lot
Thanks,
Thomas Reddy
-Original Message-
From: Chas. Owens [mailto:[EMAIL PROTECTED]
Sent: Friday, January 18, 2008 9:01 PM
To: Allam Reddy, Thomas
Cc: beginners@perl.org
Subject: Re: help me in reading the xml file
On
On Jan 18, 2008 2:45 PM, Andy Greenwood <[EMAIL PROTECTED]> wrote:
snip
> > $SIG{__DIE__} = sub {
> > open my $fh, ">>", "something.log"
> > or die @_, "could not open something.log: $!";
> > print $fh @_;
> > };
> >
> > die "Oops";
> >
>
> Would this not be susceptible to infinite
Chas. Owens wrote:
On Jan 17, 2008 9:54 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
I want to write the errors caught by a 'die' clause into a file.
snip
Try
#!/usr/bin/perl
use strict;
use warnings;
$SIG{__DIE__} = sub {
open my $fh, ">>", "something.log"
or die @_, "c
On Jan 18, 2008 10:51 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
snip
> > #!/usr/bin/perl
> >
> > use strict;
> > use warnings;
> >
> > $SIG{__DIE__} = sub {
> >open my $fh, ">>", "something.log"
> >or die @_, "could not open something.log: $!";
> >print $fh @_;
> > };
> >
> > die
-- Forwarded message --
From: Jonathan Mast <[EMAIL PROTECTED]>
Date: Jan 18, 2008 10:50 AM
Subject: Re: help me die verbosely
To: "Chas. Owens" <[EMAIL PROTECTED]>
OK, so were binding an anonymous subroutine to the DIE signal?
Does this need to go abov
On Jan 18, 2008 4:54 AM, Allam Reddy, Thomas <[EMAIL PROTECTED]> wrote:
> Hi Chas Owens,
>
> Thanks for your reply.
> Is there a way to parse and get the info from xml withou using
> XML::Twig?
snip
There are many XML parsing modules in Perl; unfortunately, none of the
are part of Core Perl. In f
Subject: Re: help me in reading the xml file
On Jan 18, 2008 4:34 AM, Allam Reddy, Thomas <[EMAIL PROTECTED]>
wrote:
> Hi Chas Owens,
>
> Thanks for your reply.
>
> I am getting the following error when running the code given in the
> mail.
>
>
> Can't locate XM
this?
-Original Message-
From: Chas. Owens [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 17, 2008 9:38 PM
To: Allam Reddy, Thomas
Cc: beginners@perl.org
Subject: Re: help me in reading the xml file
On Jan 17, 2008 5:53 AM, Allam Reddy, Thomas <[EMAIL PROTECTED]>
wrote:
snip
> I have got an
On Jan 18, 2008 4:34 AM, Allam Reddy, Thomas <[EMAIL PROTECTED]> wrote:
> Hi Chas Owens,
>
> Thanks for your reply.
>
> I am getting the following error when running the code given in the
> mail.
>
>
> Can't locate XML/Twig.pm in @INC (@INC contains:
snip
XML::Twig is not part of Core Perl. It (a
Jonathan Mast wrote:
I want to write the errors caught by a 'die' clause into a file.
In others words,
open F ">>somefile.log";
blah->blah or die (print F $@)
but the above does work.
die() sends its output to STDERR, so
open STDERR, '>', 'somefile.log' or die $!;
blah->blah or
On Jan 17, 2008 5:53 AM, Allam Reddy, Thomas <[EMAIL PROTECTED]> wrote:
snip
> I have got an xml like this below. I want to read this file in Perl and
> want to retrieve the text which end with .xml.
>
> For example , I want to print the text "jms/hppjmsmodules-jms.xml",
> since it ends with .xml
s
On Jan 17, 2008 9:54 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
> I want to write the errors caught by a 'die' clause into a file.
snip
Try
#!/usr/bin/perl
use strict;
use warnings;
$SIG{__DIE__} = sub {
open my $fh, ">>", "something.log"
or die @_, "could not open something.log:
I want to write the errors caught by a 'die' clause into a file.
In others words,
open F ">>somefile.log";
blah->blah or die (print F $@)
but the above does work.
thanks
Hi All,
I have got an xml like this below. I want to read this file in Perl and
want to retrieve the text which end with .xml.
For example , I want to print the text "jms/hppjmsmodules-jms.xml",
since it ends with .xml
Thanks in advance for your help.
http://www.bea.com/ns/weblogic/90/
Hello,
well this is more of a mod_rewrite question.
The problem is that you have to use the QUERY_STRING variable in order
to access parameters, these are not part of the normal scope of the
RewriteCond / RewriteRule stuff. Refer to the mod_rewrite guide for that.
We use this to append a use
: Help me with an url rewrite
Hmm,
then please don't post your WRONG solution sample.
-Original Message-
From: [EMAIL PROTECTED]
To: beginners@perl.org
Sent: Fri, 10 Aug 2007 6.26PM
Subject: Re: Help me with an url rewrite
Hmm,
1. I did not sent a solution.
2. I
Hmm,
then please don't post your WRONG solution sample.
-Original Message-
From: [EMAIL PROTECTED]
To: beginners@perl.org
Sent: Fri, 10 Aug 2007 6.26PM
Subject: Re: Help me with an url rewrite
Hmm,
1. I did not sent a solution.
2. I just suggested how you should
Thank you.it works perfectly.
-Original Message-
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
CC: beginners@perl.org; [EMAIL PROTECTED]
Sent: Fri, 10 Aug 2007 6.16PM
Subject: Re: Help me with an url rewrite
Hello,
well this is more of a mod_rewrite question.
The problem is that you
: Friday, August 10, 2007 1:15 PM
To: [EMAIL PROTECTED]
Cc: beginners@perl.org
Subject: Re: Help me with an url rewrite
Sorry first.
But have you looked at my question carefully?
Your solution CAN'T work at all!
-Original Message-
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; begi
Sorry first.
But have you looked at my question carefully?
Your solution CAN'T work at all!
-Original Message-
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; beginners@perl.org
CC: [EMAIL PROTECTED]
Sent: Fri, 10 Aug 2007 6.06PM
Subject: RE: Help me with an url rewrite
First, yo
lian company
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Friday, August 10, 2007 12:53 PM
To: beginners@perl.org
Cc: [EMAIL PROTECTED]
Subject: Help me with an url rewrite
I'm not sure if I've asked the correct lists,but hope I can get some
helps h
I'm not sure if I've asked the correct lists,but hope I can get some
helps here.:)
I need a mod_rewrite rule,rewrite this url:
http://abc.site.com/index.php?q1=v1
to:
http://www.site.com/index.php?q1=v1&domain=abc
I applicated this rule:
RewriteEngine on
RewriteRule ^/(.+)$ http://www
On 1/22/07, Caduceus <[EMAIL PROTECTED]> wrote:
What I want to know is would this unix perl script work in windows TIA
What happened when you tried it?
There's good information on Perl portability issues in the perlport manpage.
Good luck with it!
--Tom Phoenix
Stonehenge Perl Training
--
""Tom Phoenix"" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On 1/20/07, Caduceus <[EMAIL PROTECTED]> wrote:
>
>> I'm trying to run this perl script called "salter" on activestates
>> komodo.
>> I hope to use it with Mozilla Thunderbird. I've read Learning Perl,
>> another
>>
On 1/20/07, Caduceus <[EMAIL PROTECTED]> wrote:
I'm trying to run this perl script called "salter" on activestates komodo.
I hope to use it with Mozilla Thunderbird. I've read Learning Perl, another
perl book, went to perl.com, perl.org, pm.org, and cpan.com but nothing
seems to help. I will s
Hi:
I'm trying to run this perl script called "salter" on activestates komodo.
I hope to use it with Mozilla Thunderbird. I've read Learning Perl, another
perl book, went to perl.com, perl.org, pm.org, and cpan.com but nothing
seems to help. I will show you the script. Any help will be apprecia
On 11/27/06, flw <[EMAIL PROTECTED]> wrote:
$ perl -e '$_="a11\nb22\nc33\n"; print $_, "-"x15, "\n";s/^a.*^b.*/x/m; print'
$ perl -e '$_="a11\nb22\nc33\n"; print $_, "-"x15,
"\n";s/^a.*^b.*/x\n/ms; print'
Hope this helps!
--Tom Phoenix
Stonehenge Perl Training
--
To unsubscribe, e-mail: [
1 - 100 of 293 matches
Mail list logo