Re: automatically downloading files into a certain directory

2002-12-12 Thread Christopher G Tantalo
Anette Seiler wrote: Dear members of the list! I want to do something where I am not sure it can be done with perl... Basically a user should klick on a button on a website. Then the script should create a file with certain information from a database on the webserver (that's easy) and

Re: printing an image

2002-12-12 Thread zentara
On Thu, 12 Dec 2002 10:15:19 +0200, [EMAIL PROTECTED] (Octavian Rasnita) wrote: Hi all, Can someone give me a correct example of code that prints an image? Here's an example that is as simple as it can get: :-) ## #!/usr/bin/perl

Re: automatically downloading files into a certain directory

2002-12-12 Thread zentara
On Thu, 12 Dec 2002 09:21:37 +0100, [EMAIL PROTECTED] (Anette Seiler) wrote: I want to do something where I am not sure it can be done with perl... Basically a user should klick on a button on a website. Then the script should create a file with certain information from a database on the

Re: automatically downloading files into a certain directory

2002-12-12 Thread wiggins
On Thu, 12 Dec 2002 08:01:59 -0500, Christopher G Tantalo [EMAIL PROTECTED] wrote: Anette Seiler wrote: Dear members of the list! I want to do something where I am not sure it can be done with perl... Basically a user should klick on

GD Graphs

2002-12-12 Thread Mike(mickako)Blezien
Hello, I am going to be working on a project, that will be utilizing the GD::Graphs module to create various graph reports. I was hoping that someone could point me to some good documentation or working examples of the uses of this module... of course I've been to CPAN, but was hoping to find

RE: GD Graphs

2002-12-12 Thread wiggins
O'Reilly offers two books (or they claim the second as of Dec) on this subject that you might want to look into, I have not read/seen either so cannot provide a review sorry. http://www.oreilly.com/catalog/prowg/ http://www.oreilly.com/catalog/perlgp/ (December) http://danconia.org

Re: GD Graphs

2002-12-12 Thread Mike(mickako)Blezien
Ok, thanks, I will check it out. ;) [EMAIL PROTECTED] wrote: O'Reilly offers two books (or they claim the second as of Dec) on this subject that you might want to look into, I have not read/seen either so cannot provide a review sorry. http://www.oreilly.com/catalog/prowg/

Re: Pass an NT IIS env variable to apache UNIX cgi ??

2002-12-12 Thread Mystik Gotan
Personally, I'd write them to a file and them get them. That doesn't leave you with installing modules and so on. Plus you can get a good overview. But this is just my way. -- Bob Erinkveld (Webmaster Insane Hosts) www.insane-hosts.net MSN: [EMAIL PROTECTED] From: Kipp, James

Nested hash

2002-12-12 Thread T. Murlidharan Nair
Hi!! I have a CGI that updated a mysql database, I have a nested hash structure in it. something like $repeats{$solID[i]}{$expId[i]}{$elemenet[$i]}=1 If I am to check this hash is the inner loop written as foreach $k1 (keys %repeats){ foreach $k2 (keys

Re: Re: automatically downloading files into a certain directory

2002-12-12 Thread Mark Bergeron
You could try using a refresh. First click pulls the information from the database and stuffs it into a file. The refresh loads the link of that file and downloads it from the browser. -Original Message- From: zentara[EMAIL PROTECTED] To: [EMAIL PROTECTED] Date: Thu Dec 12 05:35:48 PST

RE: cronjob via perl

2002-12-12 Thread Peter Kappus
Hi sven (et al) Wiggins(?) has a good point about calling the script remotely. But I was trying to figure out what the script actually does and I couldn't find a value for $sql...but my guess is that it looks for new members of some sort and gives them a random password? Is this

RE: automatically downloading files into a certain directory

2002-12-12 Thread Peter Kappus
Yup...I'm afraid this isn't possible within a browser (for security reasons) but you could easily build a simple perl client that would (using LWP) make a request to a CGI and save the result locally. The problem there is the UI...If you're not using a browser to retrieve the info from a server,

cronjob via perl

2002-12-12 Thread Sven Bentlage
My provider doesn`t allow any user cronjobs, but I have to perform a regular task (set back passwords ). So I just wrote a small script to the job for me, but I am not sure if it will need to much resources (and because of this would be killed by my provider) Does anyone know a better solution

RE: cronjob via perl

2002-12-12 Thread wiggins
You could setup the script to run through CGI and then use cron on another box to curl, lynx, LWP, etc. the script at your intervals. This is obviously less secure, but you could do things like require a password, check the IP of the machine doing the call (though this can be spoofed as well,

Re: cronjob via perl

2002-12-12 Thread Octavian Rasnita
Or if you don't have another server where you can set a cron job, and if you don't need the program to run exactly at a certain interval, you can activate your program each time someone visits your front page. Then you could modify the program to be really activated only after an hour, 24 hours,

Re: Opinions - First Perl Script.

2002-12-12 Thread Rob Dixon
- Original Message - From: Paul Kraus [EMAIL PROTECTED] To: 'Perl' [EMAIL PROTECTED] Sent: Wednesday, December 11, 2002 7:33 PM Subject: Opinions - First Perl Script. This is my first real Perl program outside of the learning to Perl exercises. Any thoughts, opinions, or suggestions

Perl Manuals for Modules

2002-12-12 Thread Narayan Kumar
I am too new perl. How do I see a list of all the modules that are supported by my perl, and what do I do to man those modules. Narayan -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: manual bless

2002-12-12 Thread Ruth Albocher
Nigel Wetters wrote: On Wed, 2002-12-11 at 13:55, Ruth Albocher wrote: I need to cast a scalar reference (SCALAR0x) into a reference to an object that I can use. (in other words, bless it). How can I do it? my $object = bless $scalar_reference, 'Your::Class'; well, it's a bit more

error with external command

2002-12-12 Thread Sam Harris
I am having hard time figuring out why one of my lines is not working: systemfind . -ctime -1 -exec cp {} /opt/WWW/web_stats/logs/daily/newfiles \; the error is that : Unquoted string opt may clash with future reserved word at ./process_web_log_files.pl line 25. thanks for your help in advance.

Re: What is \000?

2002-12-12 Thread Kevin Meltzer
\000 is a null character. Cheers, Kevin On Wed, Dec 11, 2002 at 12:38:49PM -0600, Dr. Poo ([EMAIL PROTECTED]) said something similar to: What/when/where/how might one come across the ?character? '\000' - that's backslash followed by three zero's. I ask because i've just come acress a

Where to find missing examples

2002-12-12 Thread David Eason
The perl module docs, in particular HTML:Parser and HTML:PullParser, mention examples in the eg directory, which I seem to be missing, although I do have an eg folder or two Using ActiveState perl 5.8.0 Thanks in advance -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

Re: Spreadsheet::ParseExcel date problem (year is being reformatted)

2002-12-12 Thread Max
My e-mail was changed, I use bold to highlight yy (02) and (2002). Somehow the [EMAIL PROTECTED] mailing list changed this to *yy* (*02*) and ** (*2002*). So the problem isn't the asteriks but that ParseExcel converts a four character year: to a two character year: yy Anybody now

Re: Please help !! Locking mail before delivery

2002-12-12 Thread Ramprasad A Padmanabhan
There seems to be no real clean way of doing this, I can think of two ways. 1) Modify your smtp server ( sendmail ) not to process the queue automatically. If you are using sendmail you would the start up script would have sendmail -bd -q5m remove the -q5m after the end of the processing

Re: error with external command

2002-12-12 Thread Ramprasad A Padmanabhan
Sam Harris wrote: I am having hard time figuring out why one of my lines is not working: systemfind . -ctime -1 -exec cp {} /opt/WWW/web_stats/logs/daily/newfiles \; try system(find .-ctime -1-exec cp{} /opt/WWW/web_stats/logs/daily/newfiles ); on a single line and do not escape the last

RE: Spreadsheet::ParseExcel date problem (year is being reformatted)

2002-12-12 Thread NYIMI Jose (BMB)
$oSheetCR-Value #formatted value $oSheetCR-{Val} #original value José. -Original Message- From: Max [mailto:[EMAIL PROTECTED]] Sent: Tuesday, December 10, 2002 4:50 PM To: [EMAIL PROTECTED] Subject: Spreadsheet::ParseExcel date problem (year is being reformatted) When I read

Re: Perl Manuals for Modules

2002-12-12 Thread Rob Dixon
Narayan In general, on Unix: perl -MCPAN -eshell then use 'h' for help, 'm /regex/' for a list of modules matching the regex. On Windows: ppm Then 'h' for help, 'search subject' for a list of modules containing 'subject' in the name. HTH, Rob - Original Message - From:

No DB::DB routine defined (Error).

2002-12-12 Thread andres finlandes
Hello all When i try debugging my application, this error message is shown: No DB::DB routine defined at C:/Perl/lib/Cwd.pm line 151. BEGIN failed--compilation aborted at C:/Perl/lib/Cwd.pm line 151. Compilation failed in require at ..\IDE_PERL/perl5db.pl line 39. BEGIN failed--compilation

Re: error with external command

2002-12-12 Thread Rob Dixon
Hi Sam I'm a Windows person so I can help a lot, but I assume the command isn't broken over two lines as it arrived to me? Also your backslash at the end (it is part of the command I presume) should be \\. As it is you've just escaped the closing double-quote to include it in the command string,

Re: How to get the biggest integers from an array?

2002-12-12 Thread Paul Johnson
On Wed, Dec 11, 2002 at 08:44:00PM -0500, Jeff 'japhy' Pinyan wrote: On Dec 11, Paul Johnson said: On Wed, Dec 11, 2002 at 10:52:53PM +0100, Jenda Krynicky wrote: From: Rob Richardson [EMAIL PROTECTED] @website[ map $_-[0], sort { $b-[1] = $a-[1] }

RE: No DB::DB routine defined (Error).

2002-12-12 Thread NYIMI Jose (BMB)
Give a look to this archive: http://archive.develooper.com/beginners%40perl.org/msg37783.html HTH, José. -Original Message- From: andres finlandes [mailto:[EMAIL PROTECTED]] Sent: Thursday, December 12, 2002 12:18 PM To: [EMAIL PROTECTED] Subject: No DB::DB routine defined

Weekly list FAQ posting

2002-12-12 Thread casey
NAME beginners-faq - FAQ for the beginners mailing list 1 - Administriva 1.1 - I'm not subscribed - how do I subscribe? Send mail to [EMAIL PROTECTED] You can also specify your subscription email address by sending email to (assuming [EMAIL PROTECTED] is your email address):

Re: obtaining a process ID.

2002-12-12 Thread be.gomes
I am familiar with ps, this is how I am currently getting the process ID: #!/usr/bin/perl -w use strict; my $pid = `ps -axo pid,ucomm |grep proxyd|cut -f 1 -d \p\`; But I was wondering if anyone new another means of doing so. Thanks. -gomes On Thu, 12 Dec 2002 13:24:20 +0530 Ramprasad A

RE: formatting output

2002-12-12 Thread Mystik Gotan
And sprintf(), format(). -- Bob Erinkveld (Webmaster Insane Hosts) www.insane-hosts.net MSN: [EMAIL PROTECTED] From: Paul Kraus [EMAIL PROTECTED] To: 'Mariusz' [EMAIL PROTECTED], 'perl' [EMAIL PROTECTED] Subject: RE: formatting output Date: Thu, 12 Dec 2002 07:59:54 -0500

Re: obtaining a process ID.

2002-12-12 Thread Mystik Gotan
#!usr/bin/perl -wT use strict; print($$); OR #!usr/bin/perl -wT use strict; use English; print $PID; # or $PROCESS_ID. English.Pm simply changes a system variable into an english word.. -- Bob Erinkveld (Webmaster Insane Hosts) www.insane-hosts.net MSN: [EMAIL PROTECTED]

Re: Perl Manuals for Modules

2002-12-12 Thread wiggins
On Thu, 12 Dec 2002 11:02:46 -, Rob Dixon [EMAIL PROTECTED] wrote: Narayan In general, on Unix: perl -MCPAN -eshell then use 'h' for help, 'm /regex/' for a list of modules matching the regex. This appears to give you a list of

Re: obtaining a process ID.

2002-12-12 Thread Ramprasad A Padmanabhan
No Mystik he did not mean own PID he meant PID of any process the only way you can do it is with ps or send a mail to a unix group for better ideas I always do this chomp($PID = `ps -ax |grep -v grep |grep $PROCESS | awk '{print $1}'`); Mystik Gotan wrote: #!usr/bin/perl -wT use strict;

Re: obtaining a process ID.

2002-12-12 Thread Sudarshan Raghavan
On Thu, 12 Dec 2002, Ramprasad A Padmanabhan wrote: No Mystik he did not mean own PID he meant PID of any process the only way you can do it is with ps or send a mail to a unix group for better ideas I always do this chomp($PID = `ps -ax |grep -v grep |grep $PROCESS | awk '{print

Re: Spreadsheet::ParseExcel date problem (year is being reformatted)

2002-12-12 Thread Mystik Gotan
$var =~ s/.{2}$//; # ? or + should do the trick easier (instead of {2} # but this shouldn't be as bad either. It just deletes the last 2 characters, no matter what characters they are. -- Bob Erinkveld (Webmaster Insane Hosts) www.insane-hosts.net MSN: [EMAIL

Indexed man pages?

2002-12-12 Thread Rob Richardson
Greetings! Another question showing my heritage as a programmer in the world according to Microsoft: Poking around in the man pages seems to me to be a slow process, especially for one who is new to the world of Perl. Has anyone converted the man pages into the same kind of indexed help files

RE: Indexed man pages?

2002-12-12 Thread Kipp, James
Another question showing my heritage as a programmer in the world according to Microsoft: Poking around in the man pages seems to me to be a slow process, especially for one who is new to the world of Perl. Has anyone converted the man pages into the same kind of indexed help files that

Re: Sound

2002-12-12 Thread Mystik Gotan
Using cgi.pm, I suggest you use HTML to provide this interactivity, As Perl has no function for this. -- Bob Erinkveld (Webmaster Insane Hosts) www.insane-hosts.net MSN: [EMAIL PROTECTED] From: Jose Vicente Paredes Loor [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL

checksum implementation in perl

2002-12-12 Thread William.Ampeh
Hello, How do I compute the checksum of a binary file (and for that matter any file) in Perl? What I am trying to automate the download of a set of files. Now what I will love to do is to check if a file has been modified since my last download. I thought a checksum check will be the best way,

Perl Cgi/ Why?

2002-12-12 Thread Paul Kraus
With ASP.net, MONO, and sun implication why would someone still use Perl for website design. This is not a flame but simply asking for advice. I use Perl for reports and linux/unix/windows scripting. However what is to gain by using it for the web over these other technologies? What are some of

RE: Perl Cgi/ Why?

2002-12-12 Thread wiggins
Possibly better asked to beginners-cgi, but in any case. ASP - $$, M$ (and not just that it is an evil empire ;-), but portability) MONO - vaporware Sun - $$, apples and oranges? I am sure I will right a soapbox on this later, but for now those seem like 3 good quick reasons.

RE: Perl Cgi/ Why?

2002-12-12 Thread Paul Kraus
So its more of a cost justification then it is for functionality. It seem Perl and cgi would generate a greater overhead. I have no lover of Microsoft but in my business I have to choose the right tool not necessarily the Moral tool :) -Original Message- From: [EMAIL PROTECTED]

RE: Perl Cgi/ Why?

2002-12-12 Thread Brent Michalski
but, by using mod_perl, you eliminate a ton of overhead. Also, don't forget about tools such as HTML::Mason (http://www.masonhq.com) Brent

process managing in Perl

2002-12-12 Thread Olivier Moulene
I have the pid of one running process and i want to kill it and all its children. What can i do to know the pids of every children ?

RE: Perl Cgi/ Why?

2002-12-12 Thread Paul Kraus
That's just it I have not even looked at any of the things perl/cgi can do. I wanted to make sure it was worth the effort before doing it. Which is actually the heart of the original message. -Original Message- From: Brent Michalski [mailto:[EMAIL PROTECTED]] Sent: Thursday, December

RE: Indexed man pages?

2002-12-12 Thread Beau E. Cox
Hi - There is plenty of perl documentation as html files with contents and hyperlinks. I don't know of any M$ help format documentation. Won't the html pages work for you? If you really really want them in help format, why don't you tackle the job as a perl project? :) Aloha = Beau.

Re: Perl Cgi/ Why?

2002-12-12 Thread Dennis G. Wicks
Greetings; Mainly because of flexibility, but also because it is a technology that is widely and freely available and not proprietary. I commonly use one of several different platforms; Win-ME with Apache ActiveState Perl, WinNT w/Apache cygwin Perl, WinNT w/Apache ActiveState Perl, one ISP

Re: Perl Cgi/ Why?

2002-12-12 Thread Mystik Gotan
I am running on Windows and don't have much to automate for my own. I am trying to write Perl scripts on the Internet for all the things I need. I could've choose PHP, but I began learning Perl and it wasn't a bad choice. I am sure everything done with PHP can be done with Perl. And Perl has

Re: checksum implementation in perl

2002-12-12 Thread Mystik Gotan
perldoc -f stat -- Bob Erinkveld (Webmaster Insane Hosts) www.insane-hosts.net MSN: [EMAIL PROTECTED] From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: checksum implementation in perl Date: Thu, 12 Dec 2002 10:48:46 -0500 Hello, How do I compute the checksum of a binary

Re: obtaining a process ID.

2002-12-12 Thread zentara
On Wed, 11 Dec 2002 18:38:31 -0500, [EMAIL PROTECTED] (B-E-G Gomes) wrote: Looking for a simple method of getting a single process ID (for a process such as syslogd) and store it in a scalar. I've found a few methods of doing so but they haven't been pretty. I'm taking suggestions :)

Re: error with external command..explained

2002-12-12 Thread Sam Harris
The way how it is in my code is on one line, the slash at the end has to be there on unix command line for it to work !!??? so the line is : systemfind . -ctime -1 -exec cp {} /opt/WWW/web_stats/logs/daily/newfiles \; Sam Harris, Internet Services Franklin University 201 S. Grant Avenue

Spreadsheet::ParseExcel Problem

2002-12-12 Thread Balint, Jess
Hi all. I send this today to ask what in the world is going on with my program. I am getting the following error: Argument isn't numeric in le at (eval 4099) line 2. Argument isn't numeric in le at (eval 4100) line 2. Argument isn't numeric in le at (eval 4101) line 2. Line 2 of my program is

disk stats

2002-12-12 Thread Thomas Browner
Is there away that I can get disk stats from a windows machine using perl? Thomas Browner

RE: disk stats

2002-12-12 Thread Wagner, David --- Senior Programmer Analyst --- WGO
Did a search of old messages and found this one. I pasted it in a file as is and ran it from my computer and worked fine. A possible starting point for you. Wags ;) == - Original Message

Re: obtaining a process ID.

2002-12-12 Thread John W. Krahn
Be Gomes wrote: I am familiar with ps, this is how I am currently getting the process ID: #!/usr/bin/perl -w use strict; my $pid = `ps -axo pid,ucomm |grep proxyd|cut -f 1 -d \p\`; But I was wondering if anyone new another means of doing so. If you have the pgrep command: my @pids =

Re: error with external command

2002-12-12 Thread John W. Krahn
Sam Harris wrote: I am having hard time figuring out why one of my lines is not working: systemfind . -ctime -1 -exec cp {} /opt/WWW/web_stats/logs/daily/newfiles \; the error is that : Unquoted string opt may clash with future reserved word at ./process_web_log_files.pl line 25. use

Re: Perl Cgi/ Why?

2002-12-12 Thread Wiggins d'Anconia
Paul Kraus wrote: So its more of a cost justification then it is for functionality. It seem Perl and cgi would generate a greater overhead. I have no lover of Microsoft but in my business I have to choose the right tool not necessarily the Moral tool :) That would be putting words in my mouth,

RE: Perl Cgi/ Why?

2002-12-12 Thread Peter Kappus
Good points everyone! And while this IS more of a beginners-cgi question, here's my two cents anyway... Lately, I have myself have been re-evaluating my use of perl in a CGI context since, PHP is so ideally suited towards perl-like tasks and already has a vast library of prebuilt functions for

Net::SFTP causes script to exit if connection can't be made

2002-12-12 Thread Ian Zapczynski
All, I just pulled down the latest Net::SFTP from CPAN and am using it w/ Perl 5.6.1. I've used the module before and don't *think* I've seen this problem, but I can't say for sure and have only one machine to test it on. What happens is that if an SFTP connection is refused to the

stripping characters from a variable

2002-12-12 Thread Jose Malacara
Hello. I have a logfile in which every message begins with a timestamp (ex. - 20012091500). I would like to be able to remove the last 4 characters (1500) off each of these to derive the date only (2001209). It works by chopping of each character individually, but I would like to know if there

Re: stripping characters from a variable

2002-12-12 Thread Wiggins d'Anconia
perldoc -f substr http://danconia.org Jose Malacara wrote: Hello. I have a logfile in which every message begins with a timestamp (ex. - 20012091500). I would like to be able to remove the last 4 characters (1500) off each of these to derive the date only (2001209). It works by chopping of each

RE: stripping characters from a variable

2002-12-12 Thread Timothy Johnson
You can try something like this: if($ts =~ /^(\d{8})/){ #get eight sequential digit chars print $1\n; }else{ print Time stamp format invalid!\n; } -Original Message- From: Jose Malacara [mailto:[EMAIL PROTECTED]] Sent: Thursday, December 12, 2002 4:26 PM To: [EMAIL

RE: stripping characters from a variable

2002-12-12 Thread Mark Anderson
Hello. I have a logfile in which every message begins with a timestamp (ex. - 20012091500). I would like to be able to remove the last 4 characters (1500) off each of these to derive the date only (2001209). It works by chopping of each character individually, but I would like to know if there is

declaring variables

2002-12-12 Thread Mariusz
In one of my scripts I have lots of variables to declare. I wanted to type them in groups instead of one long line but I think dividing my lines trough the use of the ENTER key stops the script from working. (Although when I check the syntax through perl - c script.cgi it gives me OK).

Re: [mail_lists] RE: Perl Cgi/ Why?

2002-12-12 Thread Jim
On Thursday 12 December 2002 11:35, Paul Kraus wrote: I can think of a few things to say to these comments: | So its more of a cost justification then it is for functionality. Not for everyone. I will *never* use an m$ product for cgi...ever. Using an m$ product for cgi at this point and

Regex question

2002-12-12 Thread Johnstone, Colin
Gidday all, I have a paragraph of text, I want to convert any double quotes around quoted text to \ is this the correct reg ex $paragraph =~ s{\}{\\}g; Thanking you in anticipation Colin Johnstone

RE: Regex question

2002-12-12 Thread Johnstone, Colin
Thanks Mate, worked like a treat. Colin -Original Message- From: Aman Thind [mailto:[EMAIL PROTECTED]] Sent: Friday, December 13, 2002 16:39 To: Johnstone, Colin Subject: RE: Regex question Just add another backslash to the Substitute With part of the expression as in : $paragraph =

Re: Net::SFTP causes script to exit if connection can't be made

2002-12-12 Thread Mark Goland
how about #/usr/bin/perl -w use strict; use Net::SFTP; my ($sftp) = Net::SFTP-new(10.25.3.150, user=administrator, password=suite100) || warn connection failed $!; if (!$sftp) { print I can't connect!; } else { print SUCCESS!; } - Original Message -