Yup... That worked just great!
Thanks Jenda!
-Dan
-Original Message-
From: Jenda Krynicky [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 17, 2002 10:33 AM
To: Perl List
Subject: Re: Setting environment variable for process spawned with
system()
From: "Dan Fish" <[EMAIL PROTECTED]>
Hi there perl people of the world. I was wondering if anyone had a way to
assign the process list from Unix to an array using perl internals, not the
old " @PSINFO=`ps -ef`; " system call.
Thanx bunches!
Jim
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAI
Heyho!
My case:
I'm writing a program which analyses some input to
get some percent values. These values should be drawn
in a diagramm (is use GD for that). To use the area
of the created picture optimally I want the biggest value
(see my question of yesterday...it is solved now)
to have colu
Hi,
I'm not sure if mailing to this list is the right way of getting help, if
not I apologize in advance. I'm trying to write a client for dos that talk
to a java servlet and given all the libraries available for perl I decided
to use djgpp/perl. This is what I did:
1. I downloaded perl542b.zip an
On Thursday, July 18, 2002, at 02:26 , Hughes, James wrote:
> Hi there perl people of the world. I was wondering if anyone had a way to
> assign the process list from Unix to an array using perl internals, not
> the
> old " @PSINFO=`ps -ef`; " system call.
you will probably want to
a) opt in
From: George Schlossnagle <[EMAIL PROTECTED]>
> >> The main problem appears to be that instead of taking a different
> >> branch if open() or flock() fails you continue on as if they had
> >> succeeded.
>
> flock($fh,LOCK_EX ) is a blocking call, so it won't return until the
> l
> to have column with the maximum lenght (in my case 580 pixels).
What is length refer to ? I mean, the width or height ?
> All the other values should be drawn in relation to that.
So what is the relation ? Is that the "length" is $max_percent_value or what
?
> I thougt I can make a factor a
On Wednesday, July 17, 2002, at 07:04 , George Schlossnagle wrote:
>>> The main problem appears to be that instead of taking a different branch
>>> if open() or flock() fails you continue on as if they had succeeded.
>
> flock($fh,LOCK_EX ) is a blocking call, so it won't return until the lock
I think I have stumbled onto a bug. I'd like one of the gurus (Jeff, druiex,
Jenda or any perlguy.com) to confirm that my test is correct or if I missed
something in docs.
using Perl 5.6.1 on a Solaris sparc.
#perl
use strict;
use warnings;
my $wofile = "noread"; # text file with no read permis
On Thu, Jul 18, 2002 at 10:33:45AM -0400, Nikola Janceski wrote:
> I think I have stumbled onto a bug. I'd like one of the gurus (Jeff, druiex,
> Jenda or any perlguy.com) to confirm that my test is correct or if I missed
> something in docs.
I'm not on that list, but I'll bite anyways :-)
> usi
On Jul 18, Nikola Janceski said:
>I think I have stumbled onto a bug. I'd like one of the gurus (Jeff, druiex,
>Jenda or any perlguy.com) to confirm that my test is correct or if I missed
>something in docs.
I have confirmed the same result. The -T test on a file with no read
permissions causes
On Thu, Jul 18, 2002 at 04:53:46PM +0200, Michael Lamertz wrote:
>
> The 'stat' structure is used. That structure has been filled by the -T,
> since the file has been accessed, regardless of the fact that the test
> for the 'text' type failed.
DUH! Me Idiot, Ugh! I mixed up || and && in my ow
It appears that -T cause perl to avoid doing the stat, opting for open
and fstat instead (so that it can check the file header to see if it's
text). The open of course fails, and thus the stat does not get
populated.
On Thursday, July 18, 2002, at 11:04 AM, Michael Lamertz wrote:
> On Thu,
Dear,
I've tried to compile a script perl through perlcc, but it has returned me the
following error:
bash-2.04# perlcc teste.pl
Compiling teste.pl:
--
On Wednesday, July 17, 2002, at 09:29 , Nikola Janceski wrote:
> you for got the int.. he said whole numbers
>
> my $rand_num = int(rand(90) + 10);
>
good point! I had forgotten to be explicit
that we wanted an int...
eg:
my $int = 10;
my $count = rand($int) + $int;
Thank you Bob,
This works for me. One further question. I thought I read somewhere
that you should
not put full paths in a CGI program for security reasons. Should that be a
consideration?
Maureen
Bob Showalter wrote:
> > -Original Message-
> > From: Maureen E Fischer [mailto:[EM
On Jul 18, George Schlossnagle said:
>It appears that -T cause perl to avoid doing the stat, opting for open
>and fstat instead (so that it can check the file header to see if it's
>text). The open of course fails, and thus the stat does not get
>populated.
That's exactly what I found. My patc
At 08:28 AM 7/18/2002 -0700, Maureen E Fischer wrote:
>Thank you Bob,
> This works for me. One further question. I thought I read somewhere
>that you should
>not put full paths in a CGI program for security reasons. Should that be a
>consideration?
>Maureen
For security, you should put ful
I was wondering what the scope of perlvars (ie. $! and $?) are across
modules?
Here's my situation:
In module:
open file || return -1;
In script:
Can I use $! here? and will it contain the reason open didn't open (if it
didn't) in the module?
Would I need to export the $! from the module?
Nik
On Jul 18, Nikola Janceski said:
>I was wondering what the scope of perlvars (ie. $! and $?) are across
>modules?
Those variables are true globals. They are seen everwhere.
>In module:
>open file || return -1;
>
>In script:
>Can I use $! here? and will it contain the reason open didn't open (i
Possible need for integer forced math? I am not familar enough with GD
to know if this would help, but when doing a similar thing with
web-based on the fly generation of graphs simply supplying a length of
460.3 on an image's attributes for instance sent the browser into a tizzy.
Konrad Foe
Hi,
In my perl-5.6.1, I installed DBI-1.29, when I run the perl script to connect mysql
database, the following error is given:
Can't locate loadable object for module DBI in @INC (@INC contains:
/compbio/programs/perl-5.6.1/lib/5.6.1/alpha-dec_osf
/compbio/programs/perl-5.6.1/lib/5.6.1
/comp
Try reinstalling the module perhaps. Did you use automated installation or
manual? Were there ANY problems with the install. Are you SURE you installed
it to the appropriate directory structure for referencing? I work in 5.6.0
and use the DBI module bundled with it; are there bug reports fo
Does anyone have a suggestion for extracting file
attachments from emails? I need to setup a process
that pulls data from an email and then moves the data
and starts another process.
Any help would be great!
Thanks,
Steve
__
Do You Yahoo!?
Yahoo!
Hi nathanael,
I use perl5.6.1(symbolic link to perl) Makefile.PL, make, make test, make install to
install DBI-1.29, I am attaching the results of installation. BTW, do you know how to
install these modules.
When I install Msql-Mysql-1.2219.tar.gz, there is failed message when I 'make test':
#
On Thursday, July 18, 2002, at 09:54 , Qingjuan Gu wrote:
> Hi,
>
> In my perl-5.6.1, I installed DBI-1.29, when I run the perl script to
> connect mysql database, the following error is given:
>
> Can't locate loadable object for module DBI in @INC (@INC contains:
> /compbio/programs/perl-5.6
I use MIME::Parser, and have always loved it. It will extract
attachments to files, and you can do what you want with them.
For example:
use MIME::Parser;
my $message = ;
$parser->output_dir('/some/directory');
my $entity = $parser->parse_data(\$message);
At this point, attachments should hav
On a side note and out of laziness (I know RTFM)
Does MIME::Parser handle recursive attachments?? We attempted to home
grow a parser a couple of years ago (I realize a lot has changed since
then) but were always trapped by multiple attachments inside an
attachment, etc. which for whatever
If you mean when an attachment is a mail message with attachments...
yes.
Cheers,
Kevin
On Thu, Jul 18, 2002 at 01:33:21PM -0400, Wiggins d'Anconia ([EMAIL PROTECTED])
said something similar to:
> On a side note and out of laziness (I know RTFM)
>
> Does MIME::Parser handle recursive attac
Ok, I need to ask you guys for some help and advice.
I am working on learning Perl, but am having a hard time. I am very
familiar with C++, but Perl seems a lot more complex for some reason.
I currently have CGI Programming with Perl from O'Reilly, and Using Perl
5 for Web Programming from Que pu
The Camel.
Having said that it might be to high as well. Check out learning perl.
Here are the two links (the books are available at most decent sized
book stores and definitely from the online retailers).
http://www.oreilly.com/catalog/pperl3/ -> The Camel 3rd Edition
http://www.oreilly.com/c
Since you're having problems with decidedly Perl things, you
need to back up and lower the bar some. First, you need
to just concentrate on Perl. Buy Learning Perl and
Programming Perl from Oreilly, they are excellent books
(only buy the second after you understand the first).
Then, try writing
Hi,
I have searched cpan using ppm looking for a package to use. I would like
to write a script to edit the size of jpg's. Is there a package out there or
even a script out there that will help me with this?
I have about 2500 images that I need to resize to make them thumbs. That'
Don;t know if this is still the *right* way to do things, but
Image::Magick was always my favorite.
Basically you read the file, set the attributes, and then write the file
back out.
David Gerler wrote:
> Hi,
> I have searched cpan using ppm looking for a package to use. I would like
>
Hello everybody,
When I install Msql-Mysql-modules-1.2219.tar.gz, there is error message for 'make
test', which make my perl script can not run.
This interactive results when I install Msql-Mysql-modules-1.2219:
# perl5.6.1 Makefile.PL
Which drivers do you want to install?
1) MySQL only
>
> Ok, I need to ask you guys for some help and advice.
> I am working on learning Perl, but am having a hard time. I am very
> familiar with C++, but Perl seems a lot more complex for some reason.
> I currently have CGI Programming with Perl from O'Reilly, and
> Using Perl
> 5 for Web Program
Kevin Meltzer wrote:
>
> At this point, attachments should have been parsed out and created in
> $INCOMING_DIR. Use $entity to fondle the rest of the message as you
> want. Much more info in the docs.
Fondling mails Kevin? That doesn't sound very appealing. :-)
John
--
use Perl;
program
ful
It's still legal in 23 states! Honest!
Cheers,
Kevin
On Thu, Jul 18, 2002 at 12:33:28PM -0700, John W. Krahn ([EMAIL PROTECTED]) said
something similar to:
> Kevin Meltzer wrote:
> >
> > At this point, attachments should have been parsed out and created in
> > $INCOMING_DIR. Use $entity to fon
This isn't a Perl solution (unless you run it from a perl script...) but
it'll work. Use mogrify, part of the imagemagic software suite one
command will do the whole trick.
Matt
On Thu, 2002-07-18 at 11:56, David Gerler wrote:
> Hi,
> I have searched cpan using ppm looking for a packag
Thanks to all that gave the info. Seems that ImageMagik is the winner hands
down. :-)
David Gerler
Gerler Enterprises
PO BOX 16357
Chesapeake VA 23328
http://www.GerlerEnterprises.com/
Nationwide Dial-up from $12.45
http://www.EasySitesForLess.com/
-Original Message-
From: Matt Simonsen
I also tried to use with "sprintf" to get integers
and to avoid this problem. Doesn't work.
On Thu, 18 Jul 2002 11:46:03 -0400
"Wiggins d'Anconia" <[EMAIL PROTECTED]> wrote:
> Possible need for integer forced math? I am not familar enough with GD
> to know if this would help, but when doing
I also tried to use with "sprintf" to get integers
and to avoid this problem. Doesn't work.
On Thu, 18 Jul 2002 11:46:03 -0400
"Wiggins d'Anconia" <[EMAIL PROTECTED]> wrote:
> Possible need for integer forced math? I am not familar enough with GD
> to know if this would help, but when doing
Hello,
I'm having a heck of a time populating a hash from an SQL statement.
Here is what I have so far (which doesn't work of course)
my $SQL = qq[SELECT triid, numlegs from tri_id];
my $sth = $dbh->prepare($SQL);
$sth->execute;
no warnings 'uninitialized';
my %numlegs;
while ( %numlegs = $s
Reminder:
For those of you attending the Perl Conference #6 (or Open Source
Conference), there is a golden opportunity to get some free coaching
and consultation on your work. A Birds-of-a-Feather session on "Perl
Mentoring/Code Reviews" will be given for the third year running. Some
of the t
> -Original Message-
> From: Scott Taylor [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, July 18, 2002 5:08 PM
> To: [EMAIL PROTECTED]
> Subject: populating hash from DBI
>
>
> Hello,
>
> I'm having a heck of a time populating a hash from an SQL statement.
>
> Here is what I have so far
I forward this message to the list, so hope some others can help too..
> > > to have column with the maximum lenght (in my case 580 pixels).
> >
> > What is length refer to ? I mean, the width or height ?
>
> Is this important? Well, my columns start left an go to the right side.
> So this pixel
- Original Message -
From: "Scott Taylor" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, July 18, 2002 4:08 PM
Subject: populating hash from DBI
> Hello,
Hello,
>
> I'm having a heck of a time populating a hash from an SQL statement.
>
> Here is what I have so far (whi
At 02:20 PM 18/07/2002, Bob Showalter wrote:
>Each pass through the loop overwrites %numlegs, so it will only
>contain one entry, corresponding to the last row.
So I found.
>You can do something like this:
>
>while (my $a = $sth->fetchrow_arrayref) {
> $numlegs{$a->[0]} = $numlegs{$a-
On Thursday, July 18, 2002, at 11:35 , David Fisher wrote:
[..]
> I can find very little online oddly enough that doesn't seem over my
> head on mySQL and Perl. Does anyone have a good beginner's tutorial on
> mySQL and Perl? I understand simple file i/o, but it doesn't seem to
> apply the same a
> > to have column with the maximum lenght (in my case 580 pixels).
>
> What is length refer to ? I mean, the width or height ?
Is this important? Well, my columns start left an go to the right side.
So this pixel value is third value in the "filledRectangle" data.
filledRectangle(100,90,$col
I also tried to use with "sprintf" to get integers
and to avoid this problem. Doesn't work.
On Thu, 18 Jul 2002 11:46:03 -0400
"Wiggins d'Anconia" <[EMAIL PROTECTED]> wrote:
> Possible need for integer forced math? I am not familar enough with GD
> to know if this would help, but when doing
Well, I tried now to round the percent
values with "sprintf" befor give it for
the column calculation and it seems to
work. But this is very bad rounded. Which
module I need for "round()"?
cu
KUF
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTE
How to get folder name of current script running?
This may or may not be the current active folder but the folder where
the script is stored.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Maybe :
round
sprintf
use POSIX
use Math::Complex
use Math::Trig
I don't know which one can help, but they seems quite like what you need.
Rgds,
Connie
- Original Message -
From: "Konrad Foerstner" <[EMAIL PROTECTED]>
To: "Connie Chan" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Dose $0 the thing you want ?
Rgds,
Connie
- Original Message -
From: "chris" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, July 19, 2002 6:26 AM
Subject: How to get folder name of current script running?
> How to get folder name of current script running?
>
> This may or
On Thursday, July 18, 2002, at 11:51 , Qingjuan Gu wrote:
>
> t/ak-dbdDBD::mysql::st FETCH failed: statement contains no
> result at t/ak-dbd.t line 286.
you might want to open up that test,
it is the file
t/ak-dbd.t
since you will be able to see at about line 286 which
s
hi, how can i edit a users' filesystem quota on redhat 7.3 from a perl
script. i know that you can use the edquota program on the command line but
that is an editor-style environment and thus would require an expect
script. is there some command-line flags that work with edquota or anything
to
On Thursday, July 18, 2002, at 03:26 , chris wrote:
> How to get folder name of current script running?
### #!/usr/bin/perl -w
### use strict;
### use File::Basename qw/dirname/;
### use Cwd;
###
### my $name = $0;
### my $dir = dirname $name;
### my $curdir= cwd;
###
### print $name . " is In
I've looked throgh the recent archives. A lot of what is being discussed seems too
'advanced' for me. I guess i'm a REAL baby newbie.
Can someone please look at the following project, and tell me why it is not writing
the contents of the readfile.txt to the writefile.txt?
It's tough to learn
Chris wrote:
>
> How to get folder name of current script running?
>
> This may or may not be the current active folder but the folder where
> the script is stored.
perldoc FindBin
John
--
use Perl;
program
fulfillment
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e
>> print (@contents);
You have to print to the file handle, otherwise, nothing will
write to WRITEFILE, but to screen only.
So, you have to write as :
print WRITEFILE @contents;
>> @newcontents = ;
>> print "\n The contents of writefile.txt is $newcontents \n";
No, $newcontents here will prin
you need to add the name of the target filehandle when you write to it. for
example:
if you open writefile.txt with the filehandle WRITE, you must print to it
like so:
print WRITE "add some text";
At 18:18 18/07/2002 -0500, Carrie Lyn Brammer wrote:
>I've looked throgh the recent archives. A
Carrie Lyn Brammer wrote:
>
> I've looked throgh the recent archives. A lot of what
> is being discussed seems too 'advanced' for me. I guess
> i'm a REAL baby newbie.
>
> Can someone please look at the following project, and
> tell me why it is not writing the contents of the
> readfile.txt to
Just the thing I am looking for. I will try to read the docs first.
Thanks.
On Thu, 18 Jul 2002 16:27:06 -0700, [EMAIL PROTECTED] (John W. Krahn)
wrote:
>Chris wrote:
>>
>> How to get folder name of current script running?
>>
>> This may or may not be the current active folder but the folder w
There is a perl module Quota get it from CPAN
Mat Harris wrote:
> hi, how can i edit a users' filesystem quota on redhat 7.3 from a perl
> script. i know that you can use the edquota program on the command line
> but that is an editor-style environment and thus would require an expect
> script
If You wont take any offence I would suggest get a copy of 'perl for
dummies'. If you are already familiar with C++ I think You can start
programming in Perl within a single day
Best Of Luck
Any way I am trying to the reverse. I have worked in perl for 2 years
and now would like to start C++
Unless you are just trying to do it in one click, you can create an action
in Photoshop that you can use on each image.
- Naika
http://naikaonline.com
-Original Message-
From: David Gerler [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 18, 2002 1:35 PM
To: Matt Simonsen; Beginners
Sub
Hi all,
I have a string $line that can be a short word or a very long line, and I
want to cut it if it is longer than 20 characters, then to end it with
Is there any Perl function for chopping what is over a number of characters?
For example I have a string:
$line = "Microsoft is a big com
$line = substr($line,0,19,) . "...";
> -Original Message-
> From: Octavian Rasnita [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, July 18, 2002 11:52 PM
> To: [EMAIL PROTECTED]
> Subject: Chopping a string.
>
>
> Hi all,
>
> I have a string $line that can be a short word or a very long
> -Original Message-
> From: Toby Stuart [mailto:[EMAIL PROTECTED]]
> Sent: Friday, July 19, 2002 4:46 PM
> To: 'Octavian Rasnita'
> Cc: '[EMAIL PROTECTED]'
> Subject: RE: Chopping a string.
>
>
> $line = substr($line,0,19,) . "...";
$line = substr($line,0,19) . "..."; # removed the u
70 matches
Mail list logo