Brian Gruber wrote:
>
> Hello,
Hello,
> In the midst of learning perl, I was messing around with stuff, and I
> found the following behavior to be a bit confusing. For some reason,
> I seem to be unable to cat a \u or \l for that matter with another
> string using the . operator. Other backsla
Pedro Antonio Reche wrote:
>
> I have a table that has exponential numbers of the type 0.203E-2 and I
> will like to reformat getting rid off the exponential so that the
> previous number would look when printed as 0.00203.
> Is there any easy way to do this?
> Any help welcome.
$ perl -le' $x =
On Wed, 08 Oct 2003 17:56:03 -0700, perl wrote:
> Can someone offers some recommendation into using dates?
Take a look at CPAN [1] for Date-related modules. My personal favorite
has become Time::Piece, although all the Date::* modules should be looked
upon.
[1] http://www.cpan.org/>
--
Tore A
I would appreciate some help with this. I am learning
Perl. I have a string inputed by the user. This string
is then split, every first letter of each word in the
string is uppercased, then joined back together and
printed.
Here is my code, can anyone help? Thanks, Sara G.
!/usr/bin/perl
# Demons
On Oct 8, Sara Gribble said:
>I would appreciate some help with this. I am learning
>Perl. I have a string inputed by the user. This string
>is then split, every first letter of each word in the
>string is uppercased, then joined back together and
>printed.
>my @words = split( / /, $firstline );
Looks like you are almost there...
% perldoc -f ucfirst
On Thu, 2003-10-09 at 13:41, Sara Gribble wrote:
> I would appreciate some help with this. I am learning
> Perl. I have a string inputed by the user. This string
> is then split, every first letter of each word in the
> string is uppercase
Your solution is also amazing but where can i define the TrueType fonts for
every single word? Or the size of them, color,...
Quoting Rob Dixon <[EMAIL PROTECTED]>:
> John wrote:
> >
> > Rob Dixon wrote:
> > >
> > > John wrote:
> > > >
> > > > I want to create a doc file that will contain my tex
I guess, you're the man!
Your code works. I did not know of the Exporter.
What happens if there are several package with the same name and exported?
thanks,
rkl
> [EMAIL PROTECTED] wrote:
>
>> > my $return = do_wrap('hello');
>>
>> Doesn't this have to be MyCommon::do_wrap('hello'); ?
>
> No.
Hi!
I am trying to break down the following:
printf("numsteps=%d i=%d im=%g vfr=%g \n",numsteps,i,imeas,vforce);
into
"numsteps= numsteps i=i im=imeas vfr=vforce \n"
printf ("\noriginal cap = %g, offset = %g", *ci, cap_offset);
into
"\noriginal cap = ci, offset = cap_offset";
I am
<[EMAIL PROTECTED]> wrote:
>
> Quoting Rob Dixon <[EMAIL PROTECTED]>:
>
> > John wrote:
> > >
> > > Rob Dixon wrote:
> > > >
> > > > John wrote:
> > > > >
> > > > > I want to create a doc file that will contain my text,
> > > > > fonts, sizes as if i wrote manually.
> > > >
> > > > You can use Win3
Hi.
Nobody else has mentioned this, but I think it's nice to have a name
to write to. '[EMAIL PROTECTED]' and 'rkl' don't do a lot for me!
<[EMAIL PROTECTED]> wrote:
>
> 1 - What is the best char to use in a file template?
> Also, please give me a good regex?
>
> I will have a formatted html
Jerry Preston <[EMAIL PROTECTED]> asked:
> I am trying to break down the following:
>
>printf("numsteps=%d i=%d im=%g vfr=%g
> \n",numsteps,i,imeas,vforce);
> into
>"numsteps= numsteps i=i im=imeas vfr=vforce \n"
>
>printf ("\noriginal cap = %g, offset = %g", *ci, cap_offset);
> in
Jerry Preston wrote:
> Hi!
>
> I am trying to break down the following:
>
>printf("numsteps=%d i=%d im=%g vfr=%g \n",numsteps,i,imeas,vforce);
> into
>"numsteps= numsteps i=i im=imeas vfr=vforce \n"
>
>printf ("\noriginal cap = %g, offset = %g", *ci, cap_offset);
> into
>"\nor
Hi EVERYBODY,
i saw this "-d" switch in an "if" statement.
if (-d $file)
What does it mean, and are there more
this kind of switches and where can I find information about them.
Thanks
d a n i e l
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROT
> Hi EVERYBODY,
Hi Dr Nick
>
> i saw this "-d" switch in an "if" statement.
>
> if (-d $file)
>
> What does it mean, and are there more
> this kind of switches and where can I find information about them.
This will return 'true' is $file contains the location of a directory. More
informa
William Li wrote:
>
> Silly question, is there an equal but opposite function to chop in Perl?
> I'd like to remove the first and last character of a string and am looking
> for a simple way to do it. So far I have:
>
> # "1234567" -> "23456"
> chop($string); # "123456"
> $string = reverse($strin
Thank you Stephan :-)
>
> This will return 'true' is $file contains the location of a
> directory. More information can be found on this in the
> 'perlfunc' manpage in the 'Alphabetical Listing of Perl
> Functions' section.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional command
Hi,
I need help in simple threaded solution.
How can I join the active thread?
After I was started the thread I want him to join itself at the end and go back to the
main
Example:
# main program
$thr1=new threads \&sub_name;
$thr2=new threads \&sub_name;
$thr3=new threads \&sub_name;
$thr4=new t
From: "Rob Dixon" <[EMAIL PROTECTED]>
> Nobody else has mentioned this, but I think it's nice to have a name
> to write to. '[EMAIL PROTECTED]' and 'rkl' don't do a lot for me!
Agreed completely.
> <[EMAIL PROTECTED]> wrote:
> >
> > 1 - What is the best char to use in a file template?
> > Al
On Wed, Oct 08, 2003 at 02:44:11PM +0200, Jenda Krynicky wrote:
> From: "Rob Dixon" <[EMAIL PROTECTED]>
> > <[EMAIL PROTECTED]> wrote:
> > >
> > > 1 - What is the best char to use in a file template?
> > > Also, please give me a good regex?
> > >
> > > I will have a formatted html page with som
This method would be perfect unless i had problem with the encoding. I want to
write greek documents but i cannot.
Quoting Rob Dixon <[EMAIL PROTECTED]>:
> <[EMAIL PROTECTED]> wrote:
> >
> > Quoting Rob Dixon <[EMAIL PROTECTED]>:
> >
> > > John wrote:
> > > >
> > > > Rob Dixon wrote:
> > > > >
[EMAIL PROTECTED] wrote:
> I guess, you're the man!
>
> Your code works. I did not know of the Exporter.
>
> What happens if there are several package with the same name and exported?
>
> thanks,
> rkl
Then you have to prepend the name. For some reason the term is slipping my
mind, but a sub dec
I have the following bit of code I have written:
@temparray = `"$lcf_tools\\ntprocinfo |$lcf_tools\\grep $process"`;
foreach $temp (@temparray){
($pid,$name) = split(" ", $temp);
print LOGFILE "The process named $name is running\n";
if ($name
On Oct 8, Anthony J Segelhorst said:
>@temparray = `"$lcf_tools\\ntprocinfo |$lcf_tools\\grep $process"`;
Lose the double-quotes. You want `$lcf_tools\\ntprocinfo ...`. The
double quotes are probably not helping.
>foreach $temp (@temparray){
>($pid,$name) = split(" ", $
On Tuesday, October 7, 2003, at 11:17 PM, vaishali wrote:
I am sending the email to the [EMAIL PROTECTED] and I am sending to
you also as this is urgent.
That's why myself and many others read the beginner's list, to fix you
up as fast as possible.
Using your previous help I can able to solv
I'm doing a php to pl migration and having a little trouble. Help
appreciated!
Undefined subroutine &main::fopen called at C:\Inetpub\wwwroot\dg\index.pl
line 91.
I get the same error for filesize, fclose, explode and include.
$fd = fopen('C:\Inetpub\wwwroot\dg\menu.txt',"r");
$line = fread($fd,f
Howdy list:
Trying to do an inplace edit:
perl -pi -e 's/whatever/newstuff/;' /file/path/here
What I need to do is replace certain parts of the line for instance:
s/^$var:(.*):123:def/$var:\1:456:ghi/;
Soo if a line matches the $var at the beginning a colon, some stuff, a colon, 123, a
colo
It was Wednesday, October 08, 2003 when Dan Muey took the soap box, saying:
: Howdy list:
:
: Trying to do an inplace edit:
:
: perl -pi -e 's/whatever/newstuff/;' /file/path/here
:
: What I need to do is replace certain parts of the line for instance:
:
:
: s/^$var:(.*):123:def/$var:\1:456:g
On Oct 8, Dodo said:
>Undefined subroutine &main::fopen called at C:\Inetpub\wwwroot\dg\index.pl
>line 91.
>I get the same error for filesize, fclose, explode and include.
That's because none of those are Perl functions. You need to look at some
Perl tutorial or beginner's manual so you know wha
> First, (.*) is very greedy. You might want to limit it in
> some way, possibly with a ? modifier like (.*?), possibly by
> looking for less than . such as ([^:]*) -- anything but a colon.
>
> Second, the backwack numbers \1 .. \9 are only for the
> matching portion of a subsitution. You mus
Dan Muey wrote:
>> First, (.*) is very greedy. You might want to limit it in
>> some way, possibly with a ? modifier like (.*?), possibly by
>> looking for less than . such as ([^:]*) -- anything but a colon.
>>
>> Second, the backwack numbers \1 .. \9 are only for the
>> matching portion of a s
Hello,
I'm trying to map two files INPUT1 to INPUT2. I
believe that I've made a syntax error somewhere
because I'm not retrieving any ouput; yet I know that
there are IDs in INPUT2 (via $id2) that exist in
INPUT1 (via $id_1b).
Also, is there a general, more efficient, way to map
files that conta
David Byrne wrote:
> Hello,
>
> I'm trying to map two files INPUT1 to INPUT2. I
> believe that I've made a syntax error somewhere
> because I'm not retrieving any ouput; yet I know that
> there are IDs in INPUT2 (via $id2) that exist in
> INPUT1 (via $id_1b).
>
> Also, is there a general, more e
On Wed, 08 Oct 2003 12:39:40 +0200, Daniel Stellwagen wrote:
> if (-d $file)
>
> What does it mean, and are there more
Try 'perldoc -f -d'.
--
Tore Aursand <[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
> qx interpolates variables. by the time $1 gets to perl, it's
> already gone.
> try:
>
> print qx(perl -pi -e 's/^$u:hello:([^:]*):/$u:goodbye:\$1/;' file);
>
That did it! Thanks a million for pointing that out!
> why not simply:
>
> [panda]$ perl -pi -e
> 's/^datax:hello:([^:]*):/datax:go
Jeff 'Japhy' Pinyan wrote:
>
> On Oct 8, Dodo said:
>
> >Undefined subroutine &main::fopen called at C:\Inetpub\wwwroot\dg\index.pl
> >line 91.
> >I get the same error for filesize, fclose, explode and include.
>
> That's because none of those are Perl functions. You need to look at some
> Perl tu
<[EMAIL PROTECTED]> wrote:
>
> Quoting Rob Dixon <[EMAIL PROTECTED]>:
>
> > <[EMAIL PROTECTED]> wrote:
> >
> > Hi.
> >
> > A name would be nice...?
> >
> > All of the answers are in the module documentation. The code below shows
> > a lot of the common requirements. Anything else you can fish from
I am trying to write a mail filter that grabs the output of SpamAssassin
and drops any messages that score above a certain number of points.
As I am writing it, I want to see exactly what the perl script is
getting and outputting. It's a pretty simple script now, it does no
filtering at all, yet.
Michael Weber wrote:
>
> I am trying to write a mail filter that grabs the output of SpamAssassin
> and drops any messages that score above a certain number of points.
>
> As I am writing it, I want to see exactly what the perl script is
> getting and outputting. It's a pretty simple script now,
On Oct 8, Rob Dixon said:
>Jeff 'Japhy' Pinyan wrote:
>>
>> open BLAH, "< c:/Inetpub/wwwroot/dg/menu.txt"
>> or die "can't read c:/Inetpub/wwwroot/dg/menu.txt: $!";
>
> my $fd;
> open $fd, '< c:/Inetpub/wwwroot/dg/menu.txt';
>
>might be a better match? With $fd in place of 'BLAH' in the
>r
Hello everyone,
I've seen several references on the Perl5 Porters mailing list about
Perl 5.8.1's hash randomization. Can someone explain actually what it
is, why I'd want to use it and how to use it?
I've not seen it discussed on any of the major perl sites, just in the
weekly perl5-porters sum
On Wed, Oct 08, 2003 at 05:05:55PM -0400, Kevin Old wrote:
> Hello everyone,
>
> I've seen several references on the Perl5 Porters mailing list about
> Perl 5.8.1's hash randomization. Can someone explain actually what it
> is, why I'd want to use it and how to use it?
Perl has never guaranteed
Any one have any experience with adding nat statements to a cisco with Perl?
I'm writing a script to do that from a db run by cron and using Net::Telnet::Cisco
(which I have yet to install and experiement with)
I just want to make sure I'm doing this right or if there's a better way or ??:
Jeff 'Japhy' Pinyan wrote:
>
> On Oct 8, Rob Dixon said:
> >
> >Jeff 'Japhy' Pinyan wrote:
> >>
> >> open BLAH, "< c:/Inetpub/wwwroot/dg/menu.txt"
> >> or die "can't read c:/Inetpub/wwwroot/dg/menu.txt: $!";
> >
> > my $fd;
> > open $fd, '< c:/Inetpub/wwwroot/dg/menu.txt';
> >
> >might be a
In article <[EMAIL PROTECTED]>, R. Joseph Newton wrote:
[...]
> I'm not fond of this particular construct, but then, I'm not fond of grep,
> either. I'd rather use something called get_all_matching().
Oh, you mean 'gam' ;-)
--
Kevin Pfeiffer
International University Bremen
--
To unsubscribe,
I'm trying to convert so I can use a server that doesn't support PHP, but
I'm giving up. With my limited knowledge I think it's impossible. I was told
that the scripting was all Perl, so conversion should have been easy. But, I
guess there's some C mixed in there as well or maybe some of it is PHP
Dear all,
I have a table that has exponential numbers of the type 0.203E-2 and I
will like to reformat getting rid off the exponential so that the
previous number would look when printed as 0.00203.
Is there any easy way to do this?
Any help welcome.
Regards,
Pedro
--
To unsubscribe, e-mail: [E
I'm trying to convert so I can use a server that doesn't support PHP, but
I'm giving up. With my limited knowledge I think it's impossible. I was told
that the scripting was all Perl, so conversion should have been easy. But, I
guess there's some C mixed in there as well or maybe some of it is PHP
Kevin Old wrote:
Hello everyone,
I've seen several references on the Perl5 Porters mailing list about
Perl 5.8.1's hash randomization. Can someone explain actually what it
is, why I'd want to use it and how to use it?
The most important bit of the documentation in is in perlsec:
"Perl has never
Can someone offers some recommendation into using dates?
I will be referencing year, month,day,hour,min,sec. I will also need to
increment or decrement by hours, days, months and years.
thanks,
-rkl
-
eMail solutions by
http://www.swanmail.com
--
To un
Hello,
In the midst of learning perl, I was messing around with stuff, and I
found the following behavior to be a bit confusing. For some reason,
I seem to be unable to cat a \u or \l for that matter with another
string using the . operator. Other backslash-escaped characters
(tabs, newlines etc
51 matches
Mail list logo