Re: HTML Anchor in CGI

2003-10-17 Thread Sergei Krivov
http://server/cgi-bin/myscript.pl?id=value#myahchor is the way anchors are explained in CGI Programming with Perl by Shishir Gundavaram et al. It is not a good idea that you put suffix to your script (myscript.pl). Reciently there was a discussion in this form. According to Randal

Re: HTML Anchor in CGI

2003-10-17 Thread Andy
You should choose http://server/.../script.pl?key=value#ancor. Do play with this: http://webcode.ru/cgi-bin/test/ancor/main.pl?value=test#5 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: HTML Anchor in CGI

2003-10-17 Thread Andy
If I want to validate certain IP Address range say in an IP Address range of : 15.70.186.15-100, here where 15.70.186 is the network id and 15-100 is the host id. I want to discover all IP Addresses that fall in between 15.86.70.15 - 15.70.186.100 . what regexp do i need to use ? Do you

Re: file conversion script

2003-10-17 Thread Paul Johnson
Graham said: As you can probably tell, I'm looking for a script to convert ogg files to mp3 en-masse, while retaining filenames and important tag information. Here's what I use to create mp3s from flac files. It's basically a quick hack (doesn't check for errors, no docs or comments etc.),

Re: What is the best way to set options in a constructor

2003-10-17 Thread Rob Dixon
Wiggins D'Anconia wrote: Dan Anderson wrote: I have a package which I wanted to make an object, so I had something like the following: sub new { my $proto = shift; my $class = ref($proto) || $proto; my $self; $self-{BOOL_1} = 0; $self-{BOOL_2} = 0; # etc...

Description Search

2003-10-17 Thread Paul D. Kraus
Ok here is the scenioro I have two price lists that contain itemcode description cost list The important two are itemcode and description. One is our list the other is the price list of our major competitior. Of course they use different itemcode to identify there items then we do. I need

RE: Description Search

2003-10-17 Thread Marcos . Rebelo
This seems my University project. Some years ago I did something more or less similar. Insted of removing some words, I would just rate witch word. For instance count each word in your description and give a coeficient to it like 1 / (count * count). After for similarities you can consider to

Re: Description Search

2003-10-17 Thread Paul D. Kraus
On Fri, 17 Oct 2003 15:24:09 +0200, [EMAIL PROTECTED] wrote: This seems my University project. Some years ago I did something more or less similar. Insted of removing some words, I would just rate witch word. For instance count each word in your description and give a coeficient to it like 1 /

email (HTML) pushed/pulled into web page

2003-10-17 Thread Gregg O'Donnell
Greetings, I have a form, and the data from that form is formatted in HTML and emailed to recipients. Is there a way to save the HTML-formatted message as a separate file? And have a web page template call this file as a server-side include file? The data also goes into a CSV file; however, I

RE: Description Search

2003-10-17 Thread Marcos . Rebelo
-Original Message- From: Paul D. Kraus [mailto:[EMAIL PROTECTED] Sent: Friday, October 17, 2003 3:32 PM To: [EMAIL PROTECTED] Subject: Re: Description Search On Fri, 17 Oct 2003 15:24:09 +0200, [EMAIL PROTECTED] wrote: This seems my University project. Some years ago I did

Re: Description Search

2003-10-17 Thread Kevin Old
On Fri, 2003-10-17 at 09:04, Paul D. Kraus wrote: Ok here is the scenioro I have two price lists that contain itemcode description cost list The important two are itemcode and description. One is our list the other is the price list of our major competitior. Of course they use different

Nested quantifiers error?

2003-10-17 Thread Michael Weber
Greetings! I am attempting to parse emails on the fly after a spam filter adds a score to the headers. (SpamAssassin, if you're curious.) When I try to find out what the spam score is I am getting a weird error. Here's the lines that error out: if ( $msg[$line] =~

alias in the shell

2003-10-17 Thread Harter, Douglas
Is it possible to create an alias in the shell from within Perl? I have a command I want to use in the shell after my Perl script executes. This command can vary, so what I would prefer to do is set up an alias to execute it. I realize aliases are created differently in different shells. I

Re: Nested quantifiers error?

2003-10-17 Thread Jeff 'japhy' Pinyan
On Oct 17, Michael Weber said: When I try to find out what the spam score is I am getting a weird error. It's not that weird an error. Perl is telling you exactly what's wrong, exactly where it's wrong. if ( $msg[$line] =~ '^X-Spam-Level: ***' ) {

Re: Description Search

2003-10-17 Thread Rob Dixon
Kevin Old wrote: Also, for example purposes, say the item you want to match on is a Black Kettle and your description is Black Kettle, but their description is BLK KTTL. Would there be occurrences like this? Damn. You mean I could have bought my prosthetic black kettle more cheaply? /R :)

Re: Split multidimensional array into 4 multidimensional arrays

2003-10-17 Thread Kevin Old
On Thu, 2003-10-16 at 17:53, James Edward Gray II wrote: On Thursday, October 16, 2003, at 03:25 PM, Kevin Old wrote: James, is it possible to ask for a little more help with this? Nope, you've used up all your free answer tokens. laughs Oh, alright, just this once... Help with my

previous element in a list

2003-10-17 Thread Nandita Mullapudi
I have a list of elements- and for every element in the list, I want to carry out an operation with the previous element or the next one, as the case might be, how do I tell perl to look at the previous element? t.i.a -Nandita -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

Re: previous element in a list

2003-10-17 Thread Rob Dixon
Nandita Mullapudi wrote: I have a list of elements- and for every element in the list, I want to carry out an operation with the previous element or the next one, as the case might be, how do I tell perl to look at the previous element? Ni Nandita. This isn't straightforward in Perl. How

printing same type of files from mutiple subdirectories of a directory

2003-10-17 Thread A L
Let's say there is a directory called Top. Within the Top directory, there are 26 subdirectories named A-Z. Within each of those A-Z subdirectories contain one or more filess that ends in .txt extension. Now, to print out the content within all those .txt files, what can you do to not type

Re: previous element in a list

2003-10-17 Thread James Edward Gray II
On Friday, October 17, 2003, at 10:13 AM, Nandita Mullapudi wrote: I have a list of elements- and for every element in the list, I want to carry out an operation with the previous element or the next one, as the case might be, how do I tell perl to look at the previous element? I like: for

Re: email (HTML) pushed/pulled into web page

2003-10-17 Thread Tore Aursand
On Fri, 17 Oct 2003 06:35:13 -0700, Gregg O'Donnell wrote: I have a form, and the data from that form is formatted in HTML and emailed to recipients. Is there a way to save the HTML-formatted message as a separate file? And have a web page template call this file as a server-side include file?

RE: alias in the shell

2003-10-17 Thread LoBue, Mark
-Original Message- From: Harter, Douglas [mailto:[EMAIL PROTECTED] Sent: Friday, October 17, 2003 8:09 AM To: Beginners Mailing List Perl (E-mail) Subject: alias in the shell Is it possible to create an alias in the shell from within Perl? I have a command I want to use in the

Persistant Filehandles.

2003-10-17 Thread Daniel Staal
Ok, I'm writing an apxl to html converter and I have one little problem: I need to open a filehandle in one sub, use it in several others, and then close it in a different sub yet. I'd pass it as a parameter, but all the subs are actually called by XML::Parser, so I don't get to choose the

Re: printing same type of files from mutiple subdirectories of a directory

2003-10-17 Thread John W. Krahn
A L wrote: Let's say there is a directory called Top. Within the Top directory, there are 26 subdirectories named A-Z. Within each of those A-Z subdirectories contain one or more filess that ends in .txt extension. Now, to print out the content within all those .txt files, what can you

Re: Persistant Filehandles.

2003-10-17 Thread Steve Grazzini
On Fri, Oct 17, 2003 at 12:38:33PM -0500, Daniel Staal wrote: I need to open a filehandle in one sub, use it in several others, and then close it in a different sub yet. I'd pass it as a parameter, but all the subs are actually called by XML::Parser, so I don't get to choose the parameter

Problem in Mail::Bulkmail 3.09 module

2003-10-17 Thread Chinku Simon
Hi, I have a perl program which uses the Mail::Bulkmail v3.09 module to send out mails. The SMTP server we have is the lotus notes server. However, the number of mails that are being sent is pretty huge -- around 2000 mails in a span of 30 minutes. The perl program crashes after sending around

Re: Persistant Filehandles.

2003-10-17 Thread Daniel Staal
--On Friday, October 17, 2003 13:54 -0400 Steve Grazzini [EMAIL PROTECTED] wrote: You could use a lexically-scoped filehandle. { my $fh; sub do_open { open $fh } sub do_append { print $fh } sub do_close { close $fh } } I actually tried that, using

RE: alias in the shell

2003-10-17 Thread Wiggins d'Anconia
On Fri, 17 Oct 2003 10:21:59 -0700, LoBue, Mark [EMAIL PROTECTED] wrote: -Original Message- From: Harter, Douglas [mailto:[EMAIL PROTECTED] Sent: Friday, October 17, 2003 8:09 AM To: Beginners Mailing List Perl (E-mail) Subject:

Re: Split multidimensional array into 4 multidimensional arrays

2003-10-17 Thread James Edward Gray II
On Friday, October 17, 2003, at 10:15 AM, Kevin Old wrote: Help with my script AND Comedy! Folks, don't forget to tip your waitress... grin Thank ya. I'll be here all week. :P On Thu, 2003-10-16 at 17:53, James Edward Gray II wrote: Okay, first, just have to ask this question: Are we doing

RE: alias in the shell

2003-10-17 Thread LoBue, Mark
There is no way I know of for a child process to modify the environment of it's parent. You might try having your perl program create a script somewhere in the path, then the parent could execute it. You can also get tricky by running your perl script in the current environment

Re: previous element in a list

2003-10-17 Thread Jeff 'japhy' Pinyan
On Oct 17, Nandita Mullapudi said: I have a list of elements- and for every element in the list, I want to carry out an operation with the previous element or the next one, as the case might be, how do I tell perl to look at the previous element? I'd just do something like: my $last =

RE: Persistant Filehandles.

2003-10-17 Thread Charles K. Clarkson
Daniel Staal [EMAIL PROTECTED] : : : I actually tried that, using the following code: [code sample snipped] : : But that doesn't seem to work either. What do you mean by doesn't seem to work? : (I've tried re-creating the : HTML::Stream too, or just using the 'global' version.) : This

Re: alias in the shell

2003-10-17 Thread Steve Grazzini
On Fri, Oct 17, 2003 at 11:43:51AM -0700, LoBue, Mark wrote: You can also get tricky by running your perl script in the current environment using: . program_name (space after the dot) then your program could exit using exec('path/to/shell'); I am not sure I understood the OP but I would go

RE: alias in the shell

2003-10-17 Thread Wiggins d'Anconia
On Fri, 17 Oct 2003 11:43:51 -0700, LoBue, Mark [EMAIL PROTECTED] wrote: There is no way I know of for a child process to modify the environment of it's parent. You might try having your perl program create a script somewhere in the

RE: Persistant Filehandles.

2003-10-17 Thread Daniel Staal
--On Friday, October 17, 2003 13:46 -0500 Charles K. Clarkson [EMAIL PROTECTED] wrote: : (I've tried re-creating the : HTML::Stream too, or just using the 'global' version.) : This actually was my first try at it. Again, slide() : works fine, but slide_() doesn't, even though it gets : called.

easier way to list email addresses for multiple recipients

2003-10-17 Thread Gregg O'Donnell
I have a form that needs to send it's data to multiple recipients (35 in all); is there an easier way to do this? snip # Region office email addresss my @offices = ('[EMAIL PROTECTED]', '[EMAIL PROTECTED]', '[EMAIL PROTECTED]'); my $email_all = @offices; /snip Thanks

making a variable execute

2003-10-17 Thread perl
Can someone show me how to make this compute? my $a=2; my $b=3; my $oper=+; my $c = $a $oper $b; where $c would have a value of 5. thanks, -rkl - eMail solutions by http://www.swanmail.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

RE: making a variable execute

2003-10-17 Thread LoBue, Mark
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, October 17, 2003 3:54 PM To: [EMAIL PROTECTED] Subject: making a variable execute Can someone show me how to make this compute? my $a=2; my $b=3; my $oper=+; my $c = $a $oper $b; where

Re: alias in the shell

2003-10-17 Thread Smoot Carl-Mitchell
On Fri, 17 Oct 2003 14:32:07 -0400 Steve Grazzini [EMAIL PROTECTED] wrote: Have you actually tried . perlscript ? :-) This will not work. The shell . command for the Bourne and Korn shell effectively sources the file and expects it to contain shell commands. You can fork a shell from a

Re: easier way to list email addresses for multiple recipients

2003-10-17 Thread Wiggins d'Anconia
Gregg O'Donnell wrote: I have a form that needs to send it's data to multiple recipients (35 in all); is there an easier way to do this? snip # Region office email addresss my @offices = ('[EMAIL PROTECTED]', '[EMAIL PROTECTED]', '[EMAIL PROTECTED]'); my $email_all = @offices; /snip This is

Re: Problem in Mail::Bulkmail 3.09 module

2003-10-17 Thread Daniel Staal
--On Friday, October 17, 2003 11:28 -0700 Chinku Simon [EMAIL PROTECTED] wrote: However, the number of mails that are being sent is pretty huge -- around 2000 mails in a span of 30 minutes. The perl program crashes after sending around 700 mails with the Bulk mail error log giving the following

RE: making a variable execute

2003-10-17 Thread perl
thanks -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, October 17, 2003 3:54 PM To: [EMAIL PROTECTED] Subject: making a variable execute Can someone show me how to make this compute? my $a=2; my $b=3; my $oper=+; my $c = $a $oper $b;

File sorting by a specific date

2003-10-17 Thread Paul Harwood
I want to search a directory of log files and populate a list of those log files ONLY if they match today's date (localtime). $logs = 'c:\logs\W3SVC1'; opendir LOGS, $logs or die Can't open directory: $!\n; my @files = grep /\.TXT$/, readdir LOGS; #Right here, I am wondering if there is a

what is time?

2003-10-17 Thread perl
How can I convert it to a readable date? $now=time; print $now return 1066442632 I had tied perldoc time but it says: No documentation found for time. thanks, - eMail solutions by http://www.swanmail.com -- To unsubscribe, e-mail: [EMAIL PROTECTED]

Re: what is time?

2003-10-17 Thread Wiggins d'Anconia
[EMAIL PROTECTED] wrote: How can I convert it to a readable date? $now=time; print $now return 1066442632 I had tied perldoc time but it says: No documentation found for time. perldoc -f time perldoc -f localtime http://danconia.org -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

Re: More what is time?

2003-10-17 Thread perl
Thanks, now I know how to use perldoc. But how do I convert that time? I have an application that stores it in that format. thanks, [EMAIL PROTECTED] wrote: How can I convert it to a readable date? $now=time; print $now return 1066442632 I had tied perldoc time but it says: No

Re: what is time?

2003-10-17 Thread Daniel Staal
--On Friday, October 17, 2003 19:08 -0700 [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: How can I convert it to a readable date? $now=time; print $now return 1066442632 Time is normally given as the epoch time: the number of seconds since the beginning of the clock under UNIX (Jan 1, 1970). To

Re: More what is time?

2003-10-17 Thread Jeff 'japhy' Pinyan
On Oct 17, [EMAIL PROTECTED] said: [EMAIL PROTECTED] wrote: How can I convert it to a readable date? $now=time; print $now return 1066442632 I had tied perldoc time but it says: No documentation found for time. perldoc -f time perldoc -f localtime Thanks, now I know how to use

Re: More what is time?

2003-10-17 Thread perl
I know about localtime(time); But I was wondering if there was a formula out there like 1066442632/60/60/24 that will say today is say 2003 10 17. thanks On Oct 17, [EMAIL PROTECTED] said: [EMAIL PROTECTED] wrote: How can I convert it to a readable date? $now=time; print $now return

Re: File sorting by a specific date

2003-10-17 Thread John W. Krahn
Paul Harwood wrote: I want to search a directory of log files and populate a list of those log files ONLY if they match today's date (localtime). $logs = 'c:\logs\W3SVC1'; opendir LOGS, $logs or die Can't open directory: $!\n; my @files = grep /\.TXT$/, readdir LOGS; #Right here, I am

Re: More what is time?

2003-10-17 Thread Daniel Staal
--On Friday, October 17, 2003 20:38 -0700 [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I know about localtime(time); But I was wondering if there was a formula out there like 1066442632/60/60/24 that will say today is say 2003 10 17. scratches head Gee, I don't know what you're asking for here. I

Re: More what is time?

2003-10-17 Thread Jeff 'japhy' Pinyan
On Oct 17, [EMAIL PROTECTED] said: I know about localtime(time); But I was wondering if there was a formula out there like 1066442632/60/60/24 that will say today is say 2003 10 17. Well, localtime() also returns a list (when called in list context). # get only the values we want my ($day,

Re: alias in the shell

2003-10-17 Thread Steve Grazzini
On Fri, Oct 17, 2003 at 04:05:10PM -0700, Smoot Carl-Mitchell wrote: Steve Grazzini [EMAIL PROTECTED] wrote: Have you actually tried . perlscript ? :-) This will not work. Yes, anyone who tries it will realize this immediately. :-) system(ENVVAR=whatever; export ENVVAR; command); You