[10640] in Perl-Users-Digest
Perl-Users Digest, Issue: 4232 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Nov 16 18:07:21 1998
Date: Mon, 16 Nov 98 15:00:19 -0800
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Mon, 16 Nov 1998 Volume: 8 Number: 4232
Today's topics:
Re: $/ ?!?!? (Martien Verbruggen)
Re: [PLEASE HELP]: Eliminate spaces at end of string (Peter J. Kernan)
Automatically identifying the website user in HTML, Jav <bchapman@best.com>
Re: Beginner Book? (Erik)
Re: COBOL to PERL translator <uri@sysarch.com>
Re: compiling modules under Win95 problems (Martien Verbruggen)
Find translated name of IP address <mhanke@club-internet.fr>
Re: Find translated name of IP address (Martien Verbruggen)
Re: FRESHMAN:preview of form data, adding files etc. <cstith@dstream.net>
help ftp yesterdays files <arranp@datamail.co.nz>
Re: Holy Abounding Books, Batman! (Ilya Zakharevich)
How do i trim a string in Perl?? <xx@xxx.com>
Re: How do i trim a string in Perl?? (Martien Verbruggen)
Re: How do i trim a string in Perl?? <baliga@synopsys.com>
Re: is embedded Perl thread-safe ? (Martien Verbruggen)
Julian.pm (bug found) (Bert Tijhuis)
Re: New directories <john.wood@diamond.co.uk>
Oraperl <snene@lds.com>
Re: Perl vs C (Alan Barclay)
Re: Perl_for_Win32_FAQ (Martien Verbruggen)
Re: Printf - interesting for non-newbies <rootbeer@teleport.com>
Re: Problem with $O, need help (Martien Verbruggen)
Re: Problem with sendmail in Perl <rootbeer@teleport.com>
Re: Q: how to sort reference designators? (Greg Bacon)
ss <Ramakrishna.Pudipeddi@fmr.com>
Special: Digest Administrivia (Last modified: 12 Mar 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Mon, 16 Nov 1998 22:04:02 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: $/ ?!?!?
Message-Id: <mj142.49$Qs1.175@nsw.nnrp.telstra.net>
Please read the following information on how to choose a good subject
line: http://www.perl.com/CPAN/authors/Dean_Roehrich/subjects.post
In article <72pp9k$mf1$1@taliesin.netcom.net.uk>,
"Clinton Gormley" <cgormley@netcomuk.co.uk> writes:
> I am trying to make a copy of a file, check that the new file is the same
> size as the original, and then truncate the original to length 0.
Another way of doing that would be to move the file (perldoc -f
rename) and recreate the original with zero length, right? And that
would probably put a lot less weight on your disk and CPU.
> The original file has the format "field;field;field;field\r\n"
If you just need to make a verbatim copy of the file, then the format
really is not important.
> I have tried reading the file in line by line, with $/ ="\n" and as a whole
> (undef ($/). However, the new file seems to lose one by record (and lose a
> blank line per record) regardless of the method I use.
Are you on NT? maybe you need to binmode the file handle. Are you
certain that there is nothing else in the file?
Maybe you should just have a look at the File::Copy module, which has
a copy, and a move function.
But I'd probably just rename the file, and create a new one with the
original name.
> local @time=localtime;
nowadays, with perl 5, it's almost certain that you meant to use my
here.
I'll take the liberty of reformatting your code, because, quite
frankly, I can't read it the way it is.
I would strongly suggest that you change a bit of the logic flow of
your program, and maybe dump some stuff in subroutines. Deeply nested
code like this is very hard to read and maintain. (Is your background
in Pascal or Delphi programming maybe? :))
undef ($/);
# you'll normally see this as
# local ($/) = undef;
[snip]
# This is where the copy happens. Since $/ is undef here,
# you'd get the contents of the current file in $temp, up
# until the end of file. Note that on win32 this means that
# you will read up to the first ^Z. Use binmode on the file
# handle to make sure that doesn't bite you.
$temp=<FHIN>;
print (length ($temp),"\n");
print FHOUT $temp;
# I can't see anything wrong with this code. Since you
# unbuffered writes to FHOUT, -s should give you the right
# information right away. Are you sure that nothing is writing
# to the log file while you are reading it?
print (-s FHIN," : ",-s FHOUT,"\n");
if ((-s FHIN)==(-s FHOUT))
[snip]
Anyway, the logic of this program could be a lot simpler, depending on
your platform. On most unixes, if not all, you can just rename the
file. The process writing to the file will keep writing to the same
one, since it refers to it by its inode, and not file name. Now make
sure your server process or something closes the file, and reopens it,
by its old name. This is the way in which most server processes rotate
their log files.
Martien
--
Martien Verbruggen |
Webmaster www.tradingpost.com.au | If it isn't broken, it doesn't have
Commercial Dynamics Pty. Ltd. | enough features yet.
NSW, Australia |
------------------------------
Date: 16 Nov 1998 22:48:28 GMT
From: pete@theory2.phys.cwru.edu (Peter J. Kernan)
Subject: Re: [PLEASE HELP]: Eliminate spaces at end of string
Message-Id: <72qa3t$jj$1@pale-rider.INS.CWRU.Edu>
In article <x7sofl5upj.fsf@sysarch.com>,
Uri Guttman <uri@sysarch.com> writes:
[...snip...]
> PJK> $s=" spaces ";
> PJK> $n = '';
> PJK> for ($i = length $s;; $i--) {
> PJK> $c = substr($s,$i,1);
> PJK> next if ($c eq " " and !$n);
> PJK> $n .= $c;
> PJK> unless ($i>0) {$s = reverse $n;last}
> PJK> }
>
> i do hope you are being silly here with that code. if you are serious
> that this is a good way to do blank stripping, you need to learn some
> more perl. :-)
ma always said "serious is as serious does", here is the way i
really strip silly trailing spaces
$os = " strip silly trailing spaces ";
while (substr($os,(length $os) -1,1) eq " ") {
substr($os,(length $os) -1,1) = ''}
--
open SIG, "<$ENV{HOME}/.sig" or die "sigless! $!";
$sig = do {local $/; <SIG>}; close SIG && print<<"$sig SIG";
Pete Kernan CWRU Physics and Statistics Depts
http://theory2.phys.cwru.edu/~pete
$sig SIG
------------------------------
Date: Mon, 16 Nov 1998 14:44:43 -0800
From: Bill Chapman <bchapman@best.com>
Subject: Automatically identifying the website user in HTML, Javascript, Java, or Perl?
Message-Id: <3650AADB.14FC18D@best.com>
I am writing a club website.
I want each user to have customizations kept separately, I think
logging in every time would be far too cumbersome. I have seen some
sites, such as www.snap.com, that identify who you are without an
explicit login.
I am trying to figure out how to find out these things while the
user is running my web site so I don't have to ask him who he is.
Can one get the user's reply e-mail address using HTML, Javascript,
Java, or Perl? Anyone know of any way? Is there other information we
are privy to (to
check against people changing their reply-to to prentend to be someone
else).
Any additional information that you could tell me how to gather
would be most useful.
If it's not too much trouble, please cc my e-mail. Thanks!
Bill Chapman
------------------------------
Date: 16 Nov 1998 21:13:42 GMT
From: eln@cyberhighway.net (Erik)
Subject: Re: Beginner Book?
Message-Id: <72q4i6$j77$1@news.cyberhighway.net>
In article <3650788e.14819289@news.newsguy.com>,
jeff.kennedy@natdecsys.com (Jeff Kennedy) writes:
> I need a book geared to an ABSOLUTE BEGINNER! No perl experience, no
> programming experience, no real shell scripting experience.
>
> What would I be looking for? Not something that assumes I know
> anything!
Start with "Hooked on Phonics" and work your way from there.
--
Erik Nielsen, Cyberhighway Internet Services NOC
So far we've managed to avoid turning Perl into APL. :-)
-- Larry Wall in <199702251904.LAA28261@wall.org>
------------------------------
Date: 16 Nov 1998 16:50:53 -0500
From: Uri Guttman <uri@sysarch.com>
Subject: Re: COBOL to PERL translator
Message-Id: <x7ogq7488y.fsf@sysarch.com>
>>>>> "OM" == Oliver Muthig <oliver.muthig@ubs.com> writes:
OM> is there anything like a COBOL to PERL translator ?
no, but i have threatened people with applying my perl to cobol
translator on their code!
:-)
uri
--
Uri Guttman ----------------- SYStems ARCHitecture and Software Engineering
Perl Hacker for Hire ---------------------- Perl, Internet, UNIX Consulting
uri@sysarch.com ------------------------------------ http://www.sysarch.com
The Best Search Engine on the Net ------------- http://www.northernlight.com
------------------------------
Date: Mon, 16 Nov 1998 21:04:19 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: compiling modules under Win95 problems
Message-Id: <nr042.6$Qs1.124@nsw.nnrp.telstra.net>
In article <36503347.85707514@netnews.worldnet.att.net>,
glc@well.com (Greg L. Chapman) writes:
> The exitstatus warning is generated by this command:
>
> D:\PERL\BIN\perl D:\perl\lib\ExtUtils\xsubpp temp000 2>&1
>
> 4DOS doesn't support this redirection syntax (though 4NT,
> TakeCommand, CMD.EXE, and, of course, all the Unix shells do). I
> think it is OK to ignore this
All the unix shells?
I'd be very careful stating such a thing. tcsh and csh certainly don't
use that redirection syntax. I rather think that only close relatives
of the bourne shell do.
Martien
--
Martien Verbruggen |
Webmaster www.tradingpost.com.au | This matter is best disposed of from a
Commercial Dynamics Pty. Ltd. | great height, over water.
NSW, Australia |
------------------------------
Date: Mon, 16 Nov 1998 22:39:07 +0100
From: "Manfred Hanke" <mhanke@club-internet.fr>
Subject: Find translated name of IP address
Message-Id: <72q67h$mip$1@front6.grolier.fr>
hello
How find the translated name of IP address without the REMOTE_HOST
what sockets functions or other, must be utilized.
If you know also where I find an exempla of code.
Thank
------------------------------
Date: Mon, 16 Nov 1998 22:21:49 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Find translated name of IP address
Message-Id: <1A142.54$Qs1.175@nsw.nnrp.telstra.net>
In article <72q67h$mip$1@front6.grolier.fr>,
"Manfred Hanke" <mhanke@club-internet.fr> writes:
> hello
>
> How find the translated name of IP address without the REMOTE_HOST
> what sockets functions or other, must be utilized.
perl doesn't have a REMOTE_HOST. You probably are referring to the
environment variable set in CGI applications. If you can use it,
please do.
Otherwise, look at the gethostby* functions.
# perldoc -f gethostbyaddr
> If you know also where I find an exempla of code.
The abovementioned documentation should be plenty. You may also want
to have a look at
# perldoc Socket
# perldoc Net::hostent
Martien
--
Martien Verbruggen |
Webmaster www.tradingpost.com.au | A Freudian slip is when you say one
Commercial Dynamics Pty. Ltd. | thing but mean your mother.
NSW, Australia |
------------------------------
Date: Mon, 16 Nov 1998 15:42:46 -0600
From: "Chris Stith" <cstith@dstream.net>
Subject: Re: FRESHMAN:preview of form data, adding files etc.
Message-Id: <a%042.54$Yd2.655@news3.ispnews.com>
I'd try setting the permissions to 0700, and making the script run as the
user of the directory.
shienh gurpreet wrote in message <364FAB42.228EFCB@roogna.eng.wayne.edu>...
>Thanks to everybody who've been helping me with my question on PERL.
> I have written a script ( not very sophisticated one, it being my
>second script). It reads in the data from a form (which includes the
>user giving a file name). If that file (web page) exists, it gives the
>user an error message otherwise it goes on to create that file using
>form data. Also, once it creates that file, it adds a link pointing to
>that file on a page chosen by the user (just like a free for all links
>page, except that instead of adding links to the same page, it adds
>links to different pages).
> My problem is that if the user fills in any info incorrectly (eg.
>wrong name of an image file), even then the file is created with wrong
>info. I wish if I could show a preview of the page to the user before
>actually creating the webpage and adding link pointing to it, so that he
>can choose if he wants to create the page or make any changes.
>Also, it sounds very stupid though, but I have to chmod all my
>dirctories, to which pages could be added, to 0777, otherwise it won't
>add files to them.
>Suggestions please. Pardon me if my posts are too lengthy, but I want to
>provide complete info. Thank you.
>
------------------------------
Date: Tue, 17 Nov 1998 11:53:39 +1300
From: Arran Price <arranp@datamail.co.nz>
Subject: help ftp yesterdays files
Message-Id: <3650ACF3.3ED1@datamail.co.nz>
Hi all,
I simply want to ftp any files that are arrived less than 24 hours ago.
I cant make a list of what I have and compare it as the files are
processed and removed.
My script so far is below. I have some problems checking with the dates
etc, and its getting to be complicated enough that I figured that
someone must have found an easier way to do it. I have left alot of
print statements in that I was using for debugging.
Any suggestions appreciated.
---------- 1 owner group 1289574 Oct 19 5:37 TEST1.001
#!/usr/local/bin/perl
#Author: Arran Price
#Date: 16/10/98
#just want to ftp everything from one directory thats under 24hrs old
#what happens if theres a file over a year old?? will stuff up
substr'ing ?
#uses libnet perl library
use Net::FTP;
use Date::Manip;
chomp($HOSTNAME=`hostname`);
$TD=&ParseDate("today"); # format returned is 1998111109:53:12
$TM=substr($TD,4,2); #todays month and day
$TD=substr($TD,6,2);
$YD=&ParseDate("yesterday");
$YM=substr($YD,4,2); #yesterdays month day and time
$YD=substr($YD,6,2);
$YD=substr($YD,8,4);
#print"today = $TD ... yesterday = $YD\n";
#print"today month = $TM and day = $TD $TT\n";
#print"yesterday month = $YM and day = $YD and time $YT\n";
#remove comment following line for debugging - comment out the other
line
#$ftp = Net::FTP->new('172.20.20.59','Debug',10);
$ftp= Net::FTP->new('172.20.20.59');
$ftp->login('anonymous','myname@$HOSTNAME');
$ftp->binary();
$ftp->cwd('/mydir');
@SC=$ftp->dir;
#If theres nothing to get lets quit now
if (@SC[0] eq "")
{
exit;
}
$MC=0;
$CC=0;
#print "@SC\n";
while (@SC[$MC] ne "")
{
@myvalues=split(/\s+/,@SC[$MC]);
print"@myvalues\n"; #comment out
print"file @myvalues[8] is month @myvalues[5] and day @myvalues[6]
and time @myvalues[7]\n"; #comment out
$AD=&ParseDate("@myvalues[6]/@myvalues[5]/@myvalues[7]"); #actual
date -passes day/month
print"ad = $AD\n"; #comment out
$CM=substr($AD,4,2); #check month ie for the file we are checking
$CD=substr($AD,6,2); #check day
$CT=substr($AD,8,4); #check time
print"check month is $CM and day is $CD and time is $CT\n";
#the last check dosent work well as the format for CT is hh:m
if(($TD==$CD && $TM==$CM) || ($YD==$CD && $YM==$CM && $YT le $CT))
{
print"file is in the last couple of days\n"; #comment out
@C[$CC]=@myvalues[8];
++$CC;
}
++$MC;
}
print"files to get are\n @C\n\n";
exit;
$MC=0;
while (@C[$MC] ne "")
{
#make the filename at this end lowercase
$LC=@C[$MC];
$LC=~tr/A-Z/a-z/;
print"$LC\n";
$ftp->get(@CONTENTS[$MC],$LC.".$TDEXT");
system("chmod 664 $LC.$TDEXT");
++$MC;
}
#the blast.log file is checked by another script and will progress files
if this file is not empty
#system("echo \"Files have arrived.\" >> blast.log");
$ftp->quit;
thanks
Arran
My opinions are my own and do not reflect those of my employer.
------------------------------
Date: 16 Nov 1998 21:43:40 GMT
From: ilya@math.ohio-state.edu (Ilya Zakharevich)
Subject: Re: Holy Abounding Books, Batman!
Message-Id: <72q6ac$6lg$1@mathserv.mps.ohio-state.edu>
[A complimentary Cc of this posting was sent to I R A Aggie
<fl_aggie@thepentagon.com>],
who wrote in article <fl_aggie-1611981528140001@aggie.coaps.fsu.edu>:
> + I never read any books on perl. I learned by looking at source, tweaking it
> + and RTFM. :) Good luck!
>
> The only problem with that is you can't take it with you to restroom...
What do you think people buy laptops for?!
Ilya
------------------------------
Date: Mon, 16 Nov 1998 16:37:50 -0500
From: "xxx" <xx@xxx.com>
Subject: How do i trim a string in Perl??
Message-Id: <72q6c3$pih$1@supernews.com>
Hi,
How do i trim a string in Perl??
I need to get rid of leading and trailing spaces in a string!
Thanks in advance !
------------------------------
Date: Mon, 16 Nov 1998 22:17:42 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: How do i trim a string in Perl??
Message-Id: <aw142.53$Qs1.175@nsw.nnrp.telstra.net>
In article <72q6c3$pih$1@supernews.com>,
"xxx" <xx@xxx.com> writes:
> Hi,
> How do i trim a string in Perl??
You start by looking in the documentation that comes with perl,
specifically the FAQ.
# perldoc -q space
=head1 Found in /usr/local/lib/perl5/5.00502/pod/perlfaq4.pod
=head2 How do I strip blank space from the beginning/end of a string?
[snip]
If you don't have perl 5.005 yet:
# perldoc perlfaq4
[search for 'blank space']
Martien
--
Martien Verbruggen |
Webmaster www.tradingpost.com.au | Little girls, like butterflies, need no
Commercial Dynamics Pty. Ltd. | excuse - Lazarus Long
NSW, Australia |
------------------------------
Date: Mon, 16 Nov 1998 14:12:31 -0800
From: Yogish Baliga <baliga@synopsys.com>
To: xxx <xx@xxx.com>
Subject: Re: How do i trim a string in Perl??
Message-Id: <3650A34E.FAA95668@synopsys.com>
use
$variable =~ s/^\s*|\s*$//g;
-- Baliga
xxx wrote:
> Hi,
> How do i trim a string in Perl??
>
> I need to get rid of leading and trailing spaces in a string!
>
> Thanks in advance !
------------------------------
Date: Mon, 16 Nov 1998 21:27:57 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: is embedded Perl thread-safe ?
Message-Id: <xN042.40$Qs1.108@nsw.nnrp.telstra.net>
In article <36503594.FF408BF5@gssec.bt.co.uk>,
Peter McLaughlin <Peter.McLaughlin@gssec.bt.co.uk> writes:
> Hello.
>
> I notice that Perl has some language support for multi-threading.
only in perl 5.005 and up.
> I'm interested in embedding Perl into a multi-threaded C/C++ server.
> Is this possible ? Is the interpreter thread-safe ? I'd like
> to call a Perl subroutine with a character string input parameter
from perldelta for 5.005_02:
(There are other parts of perldelta that talk about threads, and I
advise you to read them. Compiling perl for thread support has some
interesting side effects.)
# perldoc perldelta
[snip]
Threads
WARNING: Threading is considered an experimental feature.
Details of the implementation may change without notice.
There are known limitations and some bugs. These are
expected to be fixed in future versions.
See the README.threads manpage.
This README.threads of course doesn't refer to a man page, but to the
README.threads that comes with the source of perl.
This file contains a list of known bugs, OS issues, and other useful
tidbits.
You might also want to check the documentation for the Thread::
modules.
I personally would not use threads in perl in any production code
until it is more stabilised.
Martien
--
Martien Verbruggen |
Webmaster www.tradingpost.com.au | I'm desperately trying to figure out
Commercial Dynamics Pty. Ltd. | why kamikaze pilots wore helmets - Dave
NSW, Australia | Edison
------------------------------
Date: Mon, 16 Nov 98 21:01:24 GMT
From: B.Tijhuis@inter.nl.net (Bert Tijhuis)
Subject: Julian.pm (bug found)
Message-Id: <72q3pl$g03$1@newnews.nl.uu.net>
Scott writes me:
Thanks very much for making this module available. I have encountered
one little bug when I run the attached script. I realize many other
people may have pointed this out by now. The warning I am getting is:
Parens missing around "my" list at c:\program
files\perl\site\lib\Julian.pm line 416
Useless use of a variable in void context at c:\program
files\perl\site\lib\Julian.pm line 416
Useless use of a variable in void context at c:\program
files\perl\site\lib\Julian.pm line 416
I am running: Win NT 4.0
ActiveStates build of Perl 5.0, Jul 10, 1998
Answer:
I've changed the code so now you could get the new release 1.01
please get it from
http://www.inter.nl.net/users/B.Tijhuis/perl/julian.pm
------------------------------
Date: Mon, 16 Nov 1998 22:52:04 -0000
From: "Paul Wood" <john.wood@diamond.co.uk>
Subject: Re: New directories
Message-Id: <72qa5m$1po$1@nclient3-gui.server.ntli.net>
Thanks for the help with the regexp. Any ideas with the new dirs?
They are getting created with permissions of 0755 (even though i specify
0777), and have a an owner of "nobody". This means that i can't touch them
once they've been made, and i can't chown them as i don't have write
permissions.
Can i either
1) Get the directories created under my name, or
2) Get them created with 0777 permissions?
Thanks...
-Paul Wood.
------------------------------
Date: Mon, 16 Nov 1998 22:28:04 GMT
From: Shrirang Nene <snene@lds.com>
Subject: Oraperl
Message-Id: <3650A7A7.E27210D@lds.com>
Interested in knowing whether oraperl is available for windows95 /
windowsNT ??
replies appreciated much.
thx
S
--
Shrirang Nene, Software Engineer
Logical Design Solutions
465 South Street Suite # 105
Morristown, NJ 07960
www.lds.com
snene@lds.com
(973) 971 - 0100 Ext 179
(973) 971 - 0103 ( Fax )
------------------------------
Date: 16 Nov 1998 21:07:55 GMT
From: gorilla@elaine.drink.com (Alan Barclay)
Subject: Re: Perl vs C
Message-Id: <911250473.318855@elaine.drink.com>
In article <L9P32.35$u93.87@news13.ispnews.com>,
Ethan H. Poole <ehpoole@ingress.com> wrote:
>For a much more *general* assessment:
>
>Perl will usually smoke C in terms of development time.
>
>C will nearly always (exceptions?) smoke Perl in terms of execution speed.
The second one depends on the C code. If you use some of perl's features
like regexes & associative arrays, and badly re-implement them in
C, then you can easily end up with a C program which is slower than the
perl code.
While hand crafted C code from a good programmer will always beat
perl code equivilants, most C programmers aren't that good.
------------------------------
Date: Mon, 16 Nov 1998 21:12:35 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Perl_for_Win32_FAQ
Message-Id: <7z042.39$Qs1.124@nsw.nnrp.telstra.net>
In article <36504AB4.F56E71B2@us.ibm.com>,
James Ludlow <ludlow@us.ibm.com> writes:
> George C. Hetrick wrote:
>
>> Can anyone tell me where Perl_for_Win32_FAQ.html has gone to?
> [snip]
>
> It looks like the old faq is gone (although someone must have a copy).
> The new one can be found at http://www.activestate.com .
There's a new one in the directory where the old one used to be. I
believe it's the same as the Activestate one. The links on the other
pages just haven't been updated yet. Of course, since the new ones use
a cascading style sheet (for who knows what reason), which has not
been put on CPAN, you'll have a hard time reading them, unless you
switch that off.
http://www.perl.com/CPAN/doc/FAQs/nt/
I guess people have 'synchronised' this with the ActiveState stuff,
but not entirely yet.
Martien
--
Martien Verbruggen |
Webmaster www.tradingpost.com.au | Inside every anarchy lurks an old boy
Commercial Dynamics Pty. Ltd. | network - Mitchell Kapor
NSW, Australia |
------------------------------
Date: Mon, 16 Nov 1998 22:53:27 GMT
From: Tom Phoenix <rootbeer@teleport.com>
Subject: Re: Printf - interesting for non-newbies
Message-Id: <Pine.GSO.4.02A.9811161453150.27321-100000@user2.teleport.com>
On Sat, 14 Nov 1998 vis37@my-dejanews.com wrote:
> But when I put my script on secure server (VeriSign), it began not to
> work !
When you're having trouble with a CGI program in Perl, you should first
look at the please-don't-be-offended-by-the-name Idiot's Guide to solving
such problems. It's available on CPAN.
http://www.perl.com/CPAN/
http://www.perl.org/CPAN/
http://www.perl.org/CPAN/doc/FAQs/cgi/idiots-guide.html
http://www.perl.org/CPAN/doc/manual/html/pod/
Hope this helps!
--
Tom Phoenix Perl Training and Hacking Esperanto
Randal Schwartz Case: http://www.rahul.net/jeffrey/ovs/
------------------------------
Date: Mon, 16 Nov 1998 21:30:36 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Problem with $O, need help
Message-Id: <0Q042.41$Qs1.108@nsw.nnrp.telstra.net>
In article <365041B0.F0CADEEE@gfc-net.de>,
"J|rgen Ibelgaufts" <ibelgaufts@gfc-net.de> writes:
> The documentation says that the variable $O contains this
> information, but it does not seem to work under windows.
Is that a capital O I see there? The documentation talks about $0 (a
dollar followed by a zero). :)
If you use English, you can also use $PROGRAM_NAME
Martien
--
Martien Verbruggen | My friend has a baby. I'm writing down
Webmaster www.tradingpost.com.au | all the noises the baby makes so later
Commercial Dynamics Pty. Ltd. | I can ask him what he meant - Steven
NSW, Australia | Wright
------------------------------
Date: Mon, 16 Nov 1998 22:49:38 GMT
From: Tom Phoenix <rootbeer@teleport.com>
Subject: Re: Problem with sendmail in Perl
Message-Id: <Pine.GSO.4.02A.9811161448510.27321-100000@user2.teleport.com>
On Sat, 14 Nov 1998, Adel BEN HAJ YEDDER wrote:
> Subject: Problem with sendmail in Perl
If you're using the proper commands to run another program from perl, but
the other program doesn't cooperate, then it's the other program's fault.
If you're not using the proper commands, then it's your fault. If you
aren't sure about the proper commands, you should read the program's
documentation. If you've read it and you're still not sure, you should ask
in a newsgroup about the program.
Hope this helps!
--
Tom Phoenix Perl Training and Hacking Esperanto
Randal Schwartz Case: http://www.rahul.net/jeffrey/ovs/
------------------------------
Date: 16 Nov 1998 22:02:49 GMT
From: gbacon@itsc.uah.edu (Greg Bacon)
Subject: Re: Q: how to sort reference designators?
Message-Id: <72q7e9$ii6$1@info.uah.edu>
In article <72pbbi$dff$1@nnrp1.dejanews.com>,
dave@mag-sol.com writes:
: sub ref_des_sort_function
: {
[snip]
: my ($a_alpha, $a_num, $b_alpha, $b_num);
:
: $a =~ /(^[a-zA-z]+)(\d)+$/;
: ($a_alpha, $a_num) = ($1, $2);
:
: $b =~ /(^[a-zA-z]+)(\d)+$/;
: ($b_alpha, $b_num) = ($1, $2);
:
: return ($a_alpha cmp $b_alpha) || ($a_num <=> $b_num)
: }
Please see
<URL:http://www.perl.com/CPAN/doc/FMTEYEWTK/sort.html#CODE 1.5>
Greg
--
As a general rule, don't solve puzzles that open portals to Hell.
-- Ralph Mason
------------------------------
Date: Mon, 16 Nov 1998 17:40:56 -0500
From: "Ramakrishna, Pudipeddi" <Ramakrishna.Pudipeddi@fmr.com>
Subject: ss
Message-Id: <3650A9F8.2F58678B@fmr.com>
------------------------------
Date: 12 Jul 98 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Special: Digest Administrivia (Last modified: 12 Mar 98)
Message-Id: <null>
Administrivia:
Special notice: in a few days, the new group comp.lang.perl.moderated
should be formed. I would rather not support two different groups, and I
know of no other plans to create a digested moderated group. This leaves
me with two options: 1) keep on with this group 2) change to the
moderated one.
If you have opinions on this, send them to
perl-users-request@ruby.oce.orst.edu.
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V8 Issue 4232
**************************************