RE: return array/hash ref from function

2004-05-12 Thread Charles K. Clarkson
, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: how to set env variables?

2004-05-10 Thread Charles K. Clarkson
server and is one recommended way. What happened when you tried that? : any suggestion? Show us your code. Let us confirm your reasoning. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

RE: editing files inline, searching for \n\n\n

2004-05-10 Thread Charles K. Clarkson
in $/. The 'local' function does this in a code block. { local $/ = \n\n\n; while ( DATA ) { chomp; print; } } # $/ back to its old value __END__ foo foo foo foo HTH, Prints: foo foo foo foo HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: Displaying Data in a Table

2004-05-08 Thread Charles K. Clarkson
] ) ); } return table( @rows ); } : Does anyone have any thoughts? Not on a Saturday, no. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http

RE: Perl Scripts examples

2004-05-07 Thread Charles K. Clarkson
size, add white space, reduce number of variables used, add sub routines, etc. Perlmonks has a lot of code on site. You'll probably find something interesting. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

RE: starting perl

2004-05-06 Thread Charles K. Clarkson
Charlie davis [EMAIL PROTECTED] wrote: Please stop top-posting. : From: Charles K. Clarkson [EMAIL PROTECTED] : : : The server shouldn't matter. Are you using some flavor : of Windows? The example was for Windows. : : Apache is not installed in the ActiveState Perl for : Windows

RE: To include another file in perl program

2004-04-29 Thread Charles K. Clarkson
Durai [EMAIL PROTECTED] wrote: : : $ perl runtest.pl : configure.pl did not return a true value at runtest.pl : line 4. At the bottom of each required file place a 1 like this: 1; It should be on the last line. Let us know if that fixes your problem. HTH, Charles K. Clarkson

RE: To include another file in perl program

2004-04-29 Thread Charles K. Clarkson
customary to end such a file with 1; unless you're sure it'll return true otherwise. But it's better just to put the 1;, in case you add more statements. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e

RE: joining lines

2004-04-23 Thread Charles K. Clarkson
for that. perldoc -f join HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: joining lines

2004-04-23 Thread Charles K. Clarkson
argument and returns a line from INPUT : in scalar context. But how are the numbers from the range : operator applied to the expression scalar(IN)? They're not applied. The range acts as a counter. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail

RE: printing pod

2004-04-23 Thread Charles K. Clarkson
are on doesn't have perldoc ? : : : perldoc -qa.a | perl -lpe '($_)=m((.*))' | grep Martian I have perldoc! :) And that doesn't work. :( 'grep' is not recognized as an internal or external command, operable program or batch file. Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: Problem with Code

2004-04-21 Thread Charles K. Clarkson
; printf size is \n, $size; }, $dir ); __END__ HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: creating a hash out of 2 arrays

2004-04-20 Thread Charles K. Clarkson
be (ssn = name). : : I can iterate over one array and create the hash. Is : there any inbuilt function (or a real cool piece of : code) that does the same? Nothing all that cool. You need a hash slice: my %hash; @hash{ @ssn } = @names; HTH, Charles K. Clarkson -- Mobile Homes Specialist 254

RE: what is happening here

2004-04-20 Thread Charles K. Clarkson
$_ if /()/; } I'm curious. What prompted the question? HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: Win32::ODBC - Where's my data?

2004-04-20 Thread Charles K. Clarkson
) This is a different %NAMES. It is a global variable that has not been declared. Since it was never used before, it is empty and the statement below doesn't get executed. : { : print $ID = $NAMES{$ID} \n; : } HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: Time off my 8 hours on WP XP Prof

2004-04-20 Thread Charles K. Clarkson
Wagner, David --- Senior Programmer Analyst --- WGO [EMAIL PROTECTED] wrote: : : I have looked at machine and looked at two others (one : running xp prof and one w2k). They both come back with the : correct time. The time on the machine is correct, but for : 0927 PDT I get 1627 PDT. Now

RE: cgi retaining state (even though I don't want it to)

2004-04-19 Thread Charles K. Clarkson
this script will not affect the form. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: Determining site root

2004-04-19 Thread Charles K. Clarkson
. $alternate_template_file; } HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: perl almost an adult?

2004-04-17 Thread Charles K. Clarkson
... There weren't even computers yet! :) Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: PCRE

2004-04-17 Thread Charles K. Clarkson
; } else { print out of range\n; } } __END__ I get: out of range in range in range in range out of range HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

RE: Missing sequence finder for logfiles

2004-04-16 Thread Charles K. Clarkson
Sten Berg [EMAIL PROTECTED] wrote: : : Another try : : Here is the logfile I tested on (I´ve marked were the loops starts): So is #loop1: in there or not in there? What about the dashes? Show just what is in the file. Don't add anything. : LOGFILE : - : UNNUMBERED

RE: Missing sequence finder for logfiles

2004-04-16 Thread Charles K. Clarkson
{ @$values }; return [ sort { $a = $b } keys %missing ]; } HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: How do I make a variable globally accessible without vars

2004-04-16 Thread Charles K. Clarkson
intend to accomplish with the subroutine. Why not tell us what you want to do and we'll help you get there. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org

RE: Help with Variable Scope, Regular Expressions

2004-04-15 Thread Charles K. Clarkson
the loop begins. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: perl almost an adult? [was: s/// w/o RE]

2004-04-15 Thread Charles K. Clarkson
. . . HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: getting array index inside for loop

2004-04-14 Thread Charles K. Clarkson
$index to a smaller scope. BTW, $value above is an alias. If you are needing the index to change the current value in @array you can do it by changing $value. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands

RE: I don't get it ... array

2004-04-14 Thread Charles K. Clarkson
]; Which should print something beginning with ARRAY. Like: ARRAY(0x1824228). HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first

RE: How to write a function that clears an array?

2004-04-10 Thread Charles K. Clarkson
([EMAIL PROTECTED]); @array = (); sub my_func { my $array_ref = shift; # do stuff } Actually, it makes me wonder why we are using @array at all: my_func( [ 1 .. 4 ] ); sub my_func { my $array_ref = shift; # do stuff } HTH, Charles K. Clarkson

RE: Help with Variable Scope, Regular Expressions

2004-04-08 Thread Charles K. Clarkson
. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: Help with Variable Scope, Regular Expressions

2004-04-08 Thread Charles K. Clarkson
, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 NOTE: This response is long. If you want to ask a question be responsible and delete anything that is not relevant to your question. Do NOT top post and repeat

RE: New to Perl

2004-04-05 Thread Charles K. Clarkson
david [EMAIL PROTECTED] wrote: : : Charles K. Clarkson wrote: : : david [EMAIL PROTECTED] wrote: : : : : this is impossible in Perl. show me an example : : where something is neither true nor false. : : Er, um, well ... : [snipped code] : : you simply overload bool and croak out

RE: Using $_ in a function if no argument is passed

2004-04-03 Thread Charles K. Clarkson
problem as the last suggestion. : : And what specifically would the problem be? If $arg is 0 or undef, it will fail the test and $_ will be used even though an argument was passed. Better to check the value of @_ to see if an argument was passed. HTH, Charles K. Clarkson -- Mobile Homes

RE: nested parens

2004-04-03 Thread Charles K. Clarkson
more than one element in it. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: help in find and replacing a string in a number of files

2004-04-02 Thread Charles K. Clarkson
senthil prabu [EMAIL PROTECTED] wrote: [Please post replies to the list and do not top post] : : Charles K. Clarkson [EMAIL PROTECTED] wrote: : : : : Read the file 'perlrun' included in your perl : : distribution. The section under the -i option gives : : examples of how to do

RE: New to Perl

2004-04-02 Thread Charles K. Clarkson
; use warnings; #use Data::Dumper 'Dumper'; my $foo = foo-new(); $foo-value(1); print true\n if $foo; $foo-value( undef ); print false\n unless $foo; $foo-value( 'ambiguous' ); print true\n if $foo; __END__ HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe

RE: help in find and replacing a string in a number of files

2004-04-01 Thread Charles K. Clarkson
,which I no need to : change.I want one : single script to open all these files,match the particular : string and replace them with new string. Read the file 'perlrun' included in your perl distribution. The section under the -i option gives examples of how to do this. HTH, Charles K

RE: Streaming a file to a remote user

2004-03-30 Thread Charles K. Clarkson
$written = syswrite STDOUT, $buffer, $length, $offset; $length -= $written; $offset += $written; } } close OUT; HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e

RE: Sorting Problems

2004-03-30 Thread Charles K. Clarkson
' }, ); print Dumper [EMAIL PROTECTED]; sub sortfunc { $a-{name} cmp $b-{name}; } __END__ HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org

RE: What is happening here

2004-03-30 Thread Charles K. Clarkson
WC -Sx- Jones [EMAIL PROTECTED] wrote: : : PS - I am admit that I am likely in the middle of : a nervous break-down LOL :) You should be in just the right frame of mind for delving into Parse::RecDecent. :) Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe

RE: Calendar HTML Form

2004-03-29 Thread Charles K. Clarkson
for this. So don't tell anyone you installed something. :) : Any input appreciated If you're just looking for a nice interface to input dates and if you are certain javascript works, take a look at jsCalendar. http://dynarch.com/mishoo/calendar.epl HTH, Charles K. Clarkson -- Mobile Homes

RE: string change problem

2004-03-29 Thread Charles K. Clarkson
is anything found in the parenthesis # in the regex above $new_name = lc $1; } print Old = $name\n; print New = $new_name\n; __END__ HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

RE: `next LABEL' usage

2004-03-29 Thread Charles K. Clarkson
are not opening the same file again? HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: `next LABEL' usage

2004-03-29 Thread Charles K. Clarkson
Harry Putnam [EMAIL PROTECTED] wrote: : : Charles K. Clarkson [EMAIL PROTECTED] writes: : Harry Putnam [EMAIL PROTECTED] wrote: : : [...] : : Wants to exit a while loop inside a File::Find \wanted : sub routine. Is exiting the while loop sufficient.. or : does one need to exit from

RE: string change problem

2004-03-29 Thread Charles K. Clarkson
=~ tr/A-Z/a-z/; : printOrg = $org_name\n; : print As Entered = $name\n; Sorry, Sx. That produces this: Org = perltest As Entered = pErl1234test The OP wanted: Org = perl As Entered = pErl1234test HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968

RE: Home made mail news search tool, and folded header lines

2004-03-27 Thread Charles K. Clarkson
{ my $array_ref = shift; my %hash; @hash{ @$array_ref }++; return keys %hash == @$array_ref; } But as Randy mentioned, some mail headers are allowed to appear more than once. Thus making this test invalid. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: Home made mail news search tool, and folded header lines

2004-03-27 Thread Charles K. Clarkson
Harry Putnam [EMAIL PROTECTED] wrote: : : Charles K. Clarkson [EMAIL PROTECTED] writes: : : : I wanted a way to ensure that each reg has hit at : : least once. Otherwise we don't print. So I used a : : formulation like this (Not posted previously for : : clarity

RE: HOW-TO of the Month Club (end Of MARCH Edition)

2004-03-27 Thread Charles K. Clarkson
REALLY basic next time %) Perhaps a How-To on how not to write a How-To for a perl beginners mailing list? Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org

RE: HOW-TO of the Month Club (end Of MARCH Edition)

2004-03-27 Thread Charles K. Clarkson
article. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: What to use for Perl form Validations?

2004-03-26 Thread Charles K. Clarkson
-side validation. I believe there is also a mailing list for support. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: sorting multi dimensional array

2004-03-25 Thread Charles K. Clarkson
one tell me : how do I this? Do you know how to numerically sort one column? There all the same, except that column on the end which is not numeric. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e

RE: Hash Help Needed !

2004-03-25 Thread Charles K. Clarkson
}\n; : } : } : : } HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: sort function?

2004-03-24 Thread Charles K. Clarkson
it in some manner : that I do not understand? Have you read perlfunc? The ctime field is non-portable, in particular you cannot expect it to be a 'creation time', see Files and Filesystems in the perlport manpage for details. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: Passing file name /filehandle as argument to a subroutine...

2004-03-23 Thread Charles K. Clarkson
FH; } In recent versions of perl we could use a lexical variable: sub pass1 { my( $file ) = @_; print $file; open my $fh, $file or die qq|Error opening the $file: $!|; while ( my $line = $fh ) { print $line; last; } close $fh; } HTH, Charles K

RE: populating a cgi/perl program with a text file

2004-03-23 Thread Charles K. Clarkson
allow easier information sharing down the line. An RDF schema would probably be useful here. I think the example in the book was meant to illustrate how files and forms are processed. This is not an excellent starting place for a full featured story editor. HTH, Charles K. Clarkson

RE: hash hanging up browser

2004-03-22 Thread Charles K. Clarkson
, declaring variables outside the smallest scope possible leads to problems in large scripts. Perhaps others might learn from this. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

RE: extracting data from table embedded in Word document

2004-03-21 Thread Charles K. Clarkson
? HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: extracting data from table embedded in Word document

2004-03-20 Thread Charles K. Clarkson
: have any ideas on how to pick apart the data to get : it into the DB? How about replacing the newlines in a copy of the Word file. Swap them for something that is not in the table, like ~~~. Then add them back as you read the records into your database. HTH, Charles K. Clarkson -- Mobile

RE: Opening files to read, write, etc

2004-03-20 Thread Charles K. Clarkson
$! perl will tell you the line number of the error as well. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: returning hashes, and arrays

2004-03-19 Thread Charles K. Clarkson
literals, which : might explain it. As for as perl prototyping is concerned literals and scalar variables are interchangeable. Perl is not a subset of C. It is a whole new adventure. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED

RE: returning hashes, and arrays

2004-03-18 Thread Charles K. Clarkson
:]]+)/g ); } # this returns undef. # It should do error checking return; } __END__ Spurs 94, Suns 82 1st Period (12:00) Jump Ball Robinson vs Williams (11:41) [PHX] Marion Turnaround Jump: Missed HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe

RE: returning hashes, and arrays

2004-03-18 Thread Charles K. Clarkson
); I learned to do it with a reference and tend to forget about not using the reference. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http

RE: handling multiple select with CGI

2004-03-17 Thread Charles K. Clarkson
selectname=item2 selectname=item3 prints: $VAR1 = [ 'item1', 'item2', 'item3' ]; HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

RE: sorting multi dimensional array

2004-03-17 Thread Charles K. Clarkson
, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 PS: In perl an Array of Arrays is the same thing as a Multi-dimensional Array. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first

RE: returning hashes, and arrays

2004-03-17 Thread Charles K. Clarkson
and my intent is not to do the script for you, but a little more information would aid me not pushing you into the wrong direction. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

RE: returning hashes, and arrays

2004-03-17 Thread Charles K. Clarkson
, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: returning hashes, and arrays

2004-03-17 Thread Charles K. Clarkson
, offensive rebounds, : defensive rebounds, assists, steals, turnovers, : field goals attempted, field goals made, blocks : and fouls. There are field goals in basketball?!? : Does that help? Yes. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail

RE: How do I increment a alphanumeric value?

2004-03-12 Thread Charles K. Clarkson
into 0 which then gets added to 0. : : This is the code I used to verify it would work as stated: : my $MyIds = 'ACME0001'; : for(my $MyId=0;$MyId1300;$MyId++) { : printf %s\n, $MyIds++; : } Hmmm, { local $\ = \n; print foreach 'ACME0001' .. 'ACME1300'; } HTH, Charles K. Clarkson

RE: Print Format Problem

2004-03-12 Thread Charles K. Clarkson
,$name,$name : @@ @ It looks like the tilde (~) goes on the format line, not the variable line. ~ @@ @ [snip] HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED

RE: Win32::OLE 7 Excel

2004-03-11 Thread Charles K. Clarkson
loop. The snippet you originally gave is too small. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: Sockets, Why can't I do this?

2004-03-10 Thread Charles K. Clarkson
[EMAIL PROTECTED] [EMAIL PROTECTED] wrote: : : I get an unknown error from the command prompt. Care to share the error with us? HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

RE: Nucleotide Sequencing

2004-03-10 Thread Charles K. Clarkson
. - If it is homework, read the FAQ - We don't do that. - If it is work, your boss (client) is setting an unrealistic goal. - If you need to hire one of us, check out a perl jobs list. BTW, http://bioperl.org/ has some excellent resources for biologists. HTH, Charles K. Clarkson

RE: problem with play AOA

2004-03-09 Thread Charles K. Clarkson
); dump_aoa( $right ); dump_aoa( column_join_array( $left, $right ) ); dump_aoa( column_join_array( $left, $left ) ); HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org

RE: OT: Re: subroutine definitions

2004-03-08 Thread Charles K. Clarkson
Andrew Gaffney [EMAIL PROTECTED] wrote: : : I'm currently going through and cleaning up all my code : and moving all common code to my module. Get used to doing it. In about a year you'll wonder why you did it that way and how you did anything with such terrible programming. :) Charles K

RE: running CGI locally??

2004-03-04 Thread Charles K. Clarkson
haven't mentioned the intended platform. Tell us what that OS is and what OS is no your local box and we can help point you in the right direction. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail

RE: Checking filenames? [:: ?Kinda Solved? ::]

2004-03-04 Thread Charles K. Clarkson
, instead of time(), we don't have to jump through hoops to find the month and we have a constant time stamp in an easy to use format. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

RE: Checking filenames? [:: ?Kinda Solved? ::]

2004-03-04 Thread Charles K. Clarkson
! Grasshopper ... :) Make 'Indians' an array. my( $onelittle, $twolittle, $threelittle, ) = ('Indians') x 3; HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

RE: iterating through hash of hash references

2004-03-03 Thread Charles K. Clarkson
loops which both use the default value ($_). You would probably be better off with named values or just not using two loops. use Data::Dumper 'Dumper'; print Dumper $tabledesc; HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED

RE: iterating through hash of hash references

2004-03-03 Thread Charles K. Clarkson
usually a bad idea. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: iterating through hash of hash references

2004-03-03 Thread Charles K. Clarkson
) { Try adding this: foreach my $value ( values %$ref ) { $value = '' unless defined $value; } HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

RE: subroutine definitions

2004-02-29 Thread Charles K. Clarkson
library sub routine I'm back to square one. I like perl because I tend to not have to jump through hoops to program. Protoypes limit me too much. I'd rather not have to plan so far ahead when solving a problem. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: subroutine definitions

2004-02-28 Thread Charles K. Clarkson
: to do this in a function, both arrays will get combined : within '@_'. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first

RE: Count the number of lines in a file without actually iteratin g through the file

2004-02-26 Thread Charles K. Clarkson
) = @_; $buffer_size ||= 4096; my( $buffer, $count ); while ( sysread $file_handle, $buffer, $buffer_size ) { $count += ( $buffer =~ tr/\n// ); } return $count; } HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc. Mobile Home Specialists 254 968-8328

RE: tranfering in binmode

2004-02-25 Thread Charles K. Clarkson
WC -Sx- Jones [EMAIL PROTECTED] wrote: : : But wait!!! Hope has arrived ... : : : Press any key to reformat your system... Where's the [any] key? Is it only on linux computers? Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL

RE: RSS aggregator

2004-02-25 Thread Charles K. Clarkson
Joel [EMAIL PROTECTED] wrote: : : How would I go about writing an RSS aggregator that would : output to a text file? I used XML::RSS to do something similar recently. It did all the grunt work and I just used a template for the output. HTH, Charles K. Clarkson -- Mobile Homes Specialist

RE: Reg. 'repeated pattern' matching

2004-02-25 Thread Charles K. Clarkson
would like to know how many via: header field occur and to : get each via header field value. I want to know how to loop : through each via header field to extract the value by pattern : matching expressions. What have you tried so far? What part are you stuck on? Charles K. Clarkson

RE: Rounding of floating point numbers

2004-02-24 Thread Charles K. Clarkson
on perl 5.6.1 and up. Perhaps there is something else is affecting the value of $var2. HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc. Mobile Home Specialists 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

RE: Rounding of floating point numbers

2004-02-24 Thread Charles K. Clarkson
: %s\n, $]; I don't have a surviving copy of 5.6.0 for testing. I doubt it was a problem in 5.6.0 since there is no bug fix mentioned in perl561delta of a bug fix. Can you show the code you are using for testing? HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: Rounding of floating point numbers

2004-02-24 Thread Charles K. Clarkson
'%.*f', $precision, $value + .5 * 10 ** -$precision; } HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc. Mobile Home Specialists 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http

RE: how to push a double dimensional array

2004-02-24 Thread Charles K. Clarkson
, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

RE: how to push a double dimensional array

2004-02-24 Thread Charles K. Clarkson
Öznur Tastan [EMAIL PROTECTED] wrote: : : - Original Message - : From: Charles K. Clarkson [EMAIL PROTECTED] : To: 'Öznur Tastan' [EMAIL PROTECTED]; 'Perl Lists' : [EMAIL PROTECTED] : Sent: Tuesday, February 24, 2004 8:59 PM : Subject: RE: how to push a double dimensional array

RE: how to push a double dimensional array

2004-02-24 Thread Charles K. Clarkson
Öznur Tastan [EMAIL PROTECTED] wrote: : : - Original Message - : From: Charles K. Clarkson [EMAIL PROTECTED] : : Unfortunately, I have no idea if I have helped or not. : : No you exactly helped me but now let me ask one more question. : When using a hash of array of hashes or a hash

RE: Perl: regexp

2004-02-24 Thread Charles K. Clarkson
line print the IP in the : above code?. use URI; my $url = URI-new( 'http://162.16.23.0' ); print $url-host; The biggest advantage of using the module is that it gives the same result for 'http://162.16.23.0/foo.html' and for 'http://162.16.23.0:8080/. HTH, Charles K. Clarkson

Constructors (was: RE: deleting a hash ref's contents)

2004-02-24 Thread Charles K. Clarkson
$class = shift; my $self = { file_name = undef, base= undef, path= undef, type= undef, }; bless $self; $self-initialize( @_ ) if @_; return $self; } TIA, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328

RE: error msg : can't use string as an ARRAY ref

2004-02-23 Thread Charles K. Clarkson
More on Hash of Arrays(HoA): perldsc HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc. Mobile Home Specialists 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http

RE: how to push a double dimensional array

2004-02-23 Thread Charles K. Clarkson
. If your program is huge, try to break it into a smaller portion that solves only this part of your overall program, but still show the raw input you are starting with. (Remember to change any sensitive information.) HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc

RE: how to push a double dimensional array

2004-02-23 Thread Charles K. Clarkson
guessing the code you are not showing is poorly written. Not because you are a poor programmer, but because, in the past, that has been my experience with questions on this list. You are kind of guilty by association. HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc

RE: substitution

2004-02-23 Thread Charles K. Clarkson
it right. Though I think I would disagree with Rob and use this to aid maintainability: for ( $marque ) { s/ARE/756/g; s/TYR/978/g; s/SPE/840/g; } HTH, Charles K. Clarkson -- Mobile Home Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e

RE: Eval Errors

2004-02-23 Thread Charles K. Clarkson
set. Add $|++; to the top of the script and see if they don't drop to the error handler. They do on my Windows 5.8.3 setup. HTH, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc. Mobile Home Specialists 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED

RE: Webhosting with good Perl support

2004-02-14 Thread Charles K. Clarkson
://www.tier1services.com/. If you need something cheaper or a special plan, let me know and I'll try to customize a plan just for you. HTH, Charles K. Clarkson -- Mobile Home Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

RE: Search Replace in multiple files

2004-02-06 Thread Charles K. Clarkson
, Charles K. Clarkson -- Head Bottle Washer, Clarkson Energy Homes, Inc. Mobile Home Specialists 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

<    1   2   3   4   5   6   7   8   >