[18552] in Perl-Users-Digest
Perl-Users Digest, Issue: 720 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Apr 19 14:06:36 2001
Date: Thu, 19 Apr 2001 11:05:15 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <987703515-v10-i720@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Thu, 19 Apr 2001 Volume: 10 Number: 720
Today's topics:
Re: Can't open file, dies gls@byu.edu
Re: Can't open file, dies (Abigail)
Re: Cookie/Hash help needed <bcoon@sequenom.com>
CORBA::Orbit <weber.m@gmx.de>
Re: Elisa <michael.gruys@eln.ericsson.se>
HELP: Upload file to secondary FTP server <Nigel_member@newsguy.com>
Re: HELP: Upload file to secondary FTP server (Abigail)
Re: How do I do a DF type operation? (Craig Berry)
Re: How to make my script work locally as CGI? <clinton.munden@alcatel.com>
How to read perl memory stats? <gregory.deal@unisys.com>
HTML Template Module <pdaniel8@ford.com>
Re: HTML Template Module (Me)
Re: if equal until loop exit? <smilepak@hotmail.com>
Re: if equal until loop exit? <smilepak@hotmail.com>
Re: Mailen mit Perl (Honza Pazdziora)
Re: Mailen mit Perl <ballmann@co-de.de>
Re: Mailen mit Perl <ballmann@co-de.de>
Re: Makefile question. david_kershaw@merck.com
Re: mkdir and mv (Tad McClellan)
Re: mkdir and mv nobull@mail.com
Re: Old Chestnut? DATES!! nobull@mail.com
Owner problem <brian@cs.wnmu.edu>
pdf optimization using pdfopt and a perl script 208.155.52.2 [becky]
PERL Code Generator <michaelw@elkhart.net>
Perl hashing algorithm description? <andras@mortgagestats.com>
Re: Perl hashing algorithm description? (Tad McClellan)
perl mail module and html <Martin.Bower@ib.bankgesellschaft.de>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: 19 Apr 2001 09:51:16 -0600
From: gls@byu.edu
Subject: Re: Can't open file, dies
Message-Id: <u3db4opl7.fsf@SNOW.i-did-not-set--mail-host-address--so-shoot-me>
Uri Guttman <uri@sysarch.com> writes:
> >>>>> "JK" == Jim Kroger <minorseventhSPAMBLOCK@earthlink.net> writes:
> JK> open(LOG, ">>logfile") || die "can not create \n";
>
> put in $! so you can see why it failed
Another note on "die" (to the OP and others like me who did not
realize this for years), die gives additional information if you
do NOT include the \n. We are so used to includeing the line feed
with print statements that it is natural to include it in the die
expression, but if you leave it out it will give you information
on where the error occurred.
HTH
--
Greg Snow, PhD Office: 223A TMCB
Department of Statistics Phone: (801) 378-7049
Brigham Young University Dept.: (801) 378-4505
Provo, UT 84602 email: gls@byu.edu
------------------------------
Date: Thu, 19 Apr 2001 16:59:34 +0000 (UTC)
From: abigail@foad.org (Abigail)
Subject: Re: Can't open file, dies
Message-Id: <slrn9du6bm.bqj.abigail@tsathoggua.rlyeh.net>
gls@byu.edu (gls@byu.edu) wrote on MMDCCLXXXVIII September MCMXCIII in
<URL:news:u3db4opl7.fsf@SNOW.i-did-not-set--mail-host-address--so-shoot-me>:
() Uri Guttman <uri@sysarch.com> writes:
()
() > >>>>> "JK" == Jim Kroger <minorseventhSPAMBLOCK@earthlink.net> writes:
()
() > JK> open(LOG, ">>logfile") || die "can not create \n";
() >
() > put in $! so you can see why it failed
()
() Another note on "die" (to the OP and others like me who did not
() realize this for years), die gives additional information if you
() do NOT include the \n. We are so used to includeing the line feed
() with print statements that it is natural to include it in the die
() expression, but if you leave it out it will give you information
() on where the error occurred.
Usually, I don't care at all on which line the error occurs.
Specially not on dies with a failed open. It usually means a
condition to run the program succesfully isn't met - the answer
isn't in changing the program, but in making sure the condition
is met. ;-)
Abigail
--
echo "==== ======= ==== ======"|perl -pes/=/J/|perl -pes/==/us/|perl -pes/=/t/\
|perl -pes/=/A/|perl -pes/=/n/|perl -pes/=/o/|perl -pes/==/th/|perl -pes/=/e/\
|perl -pes/=/r/|perl -pes/=/P/|perl -pes/=/e/|perl -pes/==/rl/|perl -pes/=/H/\
|perl -pes/=/a/|perl -pes/=/c/|perl -pes/=/k/|perl -pes/==/er/|perl -pes/=/./;
------------------------------
Date: Thu, 19 Apr 2001 08:42:00 -0700
From: Bryan Coon <bcoon@sequenom.com>
Subject: Re: Cookie/Hash help needed
Message-Id: <3ADF0748.C1F82D25@sequenom.com>
Thanks, that is very helpful. I will take another look to see about the
array/value thing.
Where can I find an example of the public API however? I certainly do not
want to do something bizzare and unique here, just store the login password
values in a cookie for later retrieval.
Thanks again,
Bryan
> By using {value} on a CGI::Cookie object you are bypassing the public
> API and looking at the object's internals. You should, strictly
> speaking, use the value() method. Not that this helps much as you'll
> still get the same list ('-pass', 'password', '-logname','login').
>
> To convert a list to a hash use an assignment:
>
> my %cookie_value = $cookie{cookiename}->value;
> my $password = $cookie_value{-pass};
> my $logname = $cookie_value{-logname};
>
> Or if you want to avoid a named temporary hash use the { } operator
> and a slice:
>
> my ($logname,$password) =
> @{{$cookie{cookiename}->value}}{qw(-logname -pass)};
>
> --
> \\ ( )
> . _\\__[oo
> .__/ \\ /\@
> . l___\\
> # ll l\\
> ###LL LL\\
------------------------------
Date: Thu, 19 Apr 2001 18:10:22 +0200
From: "Mathias-H. Weber" <weber.m@gmx.de>
Subject: CORBA::Orbit
Message-Id: <3ADF0DEE.D390BDC0@gmx.de>
I have encountered problems using the module CORBA-ORBit-0.4.3:
I installed it as usual and started the included server and client
program:
- perl server&
- perl client
The result is the following error message:
---8<-------------------------------------------
incomplete message received at server line 183.
Exception: CORBA::BAD_PARAM ('IDL:omg.org/CORBA/BAD_PARAM:1.0')
(0, COMPLETED_NO)
An invalid parameter was passed
---8<-------------------------------------------
Somebody had the suspicion that this module does not work with version
of orbit > 0.5.4. My orbit version is 0.5.6. My perl version is 5.6.0.
Does anybody have a clue?
--
Mathias-H.Weber __/ mailto:weber.m@gmx.de
------------------------------
Date: Thu, 19 Apr 2001 16:11:53 +0200
From: Michael Gruys <michael.gruys@eln.ericsson.se>
Subject: Re: Elisa
Message-Id: <3ADEF229.22FE6A8F@eln.ericsson.se>
Jan Klunder wrote:
> Because of the continuing interest in Elisa and Domain Orientation we have
> improved the facilities for the visitors of the Elisa website
> http://www.xs4all.nl/~jklunder ) to share their views and opinions with
> other visitors.
>
> Jan Klunder
Has nothing to do with this newsgroup! Yak!
------------------------------
Date: 19 Apr 2001 08:09:15 -0700
From: Nigel Heinsius <Nigel_member@newsguy.com>
Subject: HELP: Upload file to secondary FTP server
Message-Id: <9bmv2r02ugg@drn.newsguy.com>
I need to write a script that allows someone to upload a file to an anonymous
FTP server. The script would run on a UNIX box, but the FTP server is a Windows
box. Is it possible to do such a thing without having to write the file first to
the UNIX box? I've never written an upload routine so any advice would be
helpful.
Thanks,
nigel
------------------------------
Date: Thu, 19 Apr 2001 17:00:19 +0000 (UTC)
From: abigail@foad.org (Abigail)
Subject: Re: HELP: Upload file to secondary FTP server
Message-Id: <slrn9du6d3.bqj.abigail@tsathoggua.rlyeh.net>
Nigel Heinsius (Nigel_member@newsguy.com) wrote on MMDCCLXXXVIII
September MCMXCIII in <URL:news:9bmv2r02ugg@drn.newsguy.com>:
-: I need to write a script that allows someone to upload a file to an anonymous
-: FTP server. The script would run on a UNIX box, but the FTP server is a Windows
-: box. Is it possible to do such a thing without having to write the file first to
-: the UNIX box? I've never written an upload routine so any advice would be
-: helpful.
Net::FTP.
Abigail
--
:;$:=~s:
-:;another Perl Hacker
:;chop
$:;$:=~y
:;::d;print+Just.
$:;
------------------------------
Date: Thu, 19 Apr 2001 17:19:04 -0000
From: cberry@cinenet.net (Craig Berry)
Subject: Re: How do I do a DF type operation?
Message-Id: <tdu7g8d01egucb@corp.supernews.com>
Dave Saville (dave.nospam@cwcom.net) wrote:
: I need to be able to find the amount of free space in a file system.
: Unix df in a system call is not an option as I need to run on multiple
: platforms.
There is no platform-independent way to determine this, alas.
--
| Craig Berry - http://www.cinenet.net/~cberry/
--*-- "When the going gets weird, the weird turn pro."
| - Hunter S. Thompson
------------------------------
Date: Thu, 19 Apr 2001 09:53:55 -0400
From: Clinton Munden <clinton.munden@alcatel.com>
Subject: Re: How to make my script work locally as CGI?
Message-Id: <3ADEEDF3.BD551F9E@alcatel.com>
Actually, in the time that it takes you to read this thread, you could have
Apache configured and running. Literally takes about only two minutes.
Clinton Munden
Alcatel Canada
Jonas Nilsson wrote:
> Is there a way I can run my perl-scripts using a web-browser, and directing
> the output to the browser. (Just like an ordinary CGI-script)
>
> I don't want to install a web-server.
>
> I use:
> WinNT 4.00.1381; IE 5.5.50.4522.1800; perl, v5.6.0 built for
> MSWin32-x86-multi-thread
>
> Sorry if I passed the border of what's relevant in this newsgroup. At least
> I considered this before posting, and decided that it's relevant enough. (I
> may be wrong ... )
>
> Feel free to ignore /jN
>
> --
> _______________________________
> Jonas Nilsson
------------------------------
Date: Thu, 19 Apr 2001 10:10:11 -0400
From: "Gregory K. Deal" <gregory.deal@unisys.com>
Subject: How to read perl memory stats?
Message-Id: <9bmrg1$bvh$1@trsvr.tr.unisys.com>
I'm still trying to determine why my perl 5.6 program dies with an "Out of
memory!" error. It's creating some rather large data structures (probably
around 1.5GB if it completed). Its memory usage is about 965 MB when it
dies, even though another program on the system (HP 5000, 4GB real memory,
4GB swap) is running at just over 1GB. I checked all the kernel values and
they are way above these numbers. I used the environment variable
PERL_DEBUG_MSTATS to get perl to dump some memory statistics. Its output is
below. Does anyone know how to read the results? Does it point to any
particular kernel parameter that it is exceeding? In the past, increasing
maxdsize fixed up programs that had memory problems. Now that it is about
3.2GB, I'm surprised that a 965MB program has problems. Thanks for any help.
(kernel parameters)
* Tunable parameters
STRMSGSZ 65535
default_disk_ir 1
maxdsiz 3221225472
maxdsiz_64bit 3800000000
maxfiles 1024
maxfiles_lim 2048
maxssiz 83570688
maxssiz_64bit 83570688
maxswapchunks 4800
maxtsiz 1073741824
maxuprc 150
maxusers 250
ninode 5000
nproc 3000
nstrpty 60
Version :
trj5000c (gkd) 9:56am ~ [504] % /trj5000a/users1/gnu/perl5.6/bin/perl -v
This is perl, v5.6.0 built for 9000/777-hpux
Copyright 1987-2000, Larry Wal
(just started program . . .)
Memory statistics :
Memory allocation statistics after compilation: (buckets 4(4)..16376(16384)
32752 free: 191 74 34 23 2 1 3 2 1 0 0 1
396 94 42 14 8
80732 used: 64 53 470 70 14 7 9 12 2 2 1 0
115 76 213 238 17
Total sbrk(): 117984/18:166. Odd ends: pad+heads+chain+tail:
1248+1204+0+2048.
(program running along . . .)
Read 1740000 lines
Read 1750000 lines
Read 1760000 lines
Out of memory!
Memory allocation statistics after execution: (buckets
4(4)..8392696(8388608)
11600 free: 152 37 11 28 5 6 3 0 0 0 0 0 0 0 0 0
0 0 0 0 0
146 4 77 16 10
975739352 used: 877558 1285076 3356944 693473 107611 1722 4781 420038 3 1
1 3 0 0 0 0 0 1 1 0 1
1281442 6823966 285948 4420274 452265
Total sbrk(): 987946208/312:459. Odd ends: pad+heads+chain+tail:
1248+12194008+0+0.
------------------------------
Date: Thu, 19 Apr 2001 10:22:35 -0400
From: "Priscilla Daniel" <pdaniel8@ford.com>
Subject: HTML Template Module
Message-Id: <9bmsbc$len2@eccws12.dearborn.ford.com>
Hi All,
Could anyone please tell me how I could use html templates in my code.
Roopa
------------------------------
Date: 19 Apr 2001 16:09:20 GMT
From: me@nospam.com (Me)
Subject: Re: HTML Template Module
Message-Id: <Xns90885C99F7465mememeyeahme@206.165.3.70>
"Priscilla Daniel" <pdaniel8@ford.com> wrote in
<9bmsbc$len2@eccws12.dearborn.ford.com>:
> Could anyone please tell me how I could use html templates in my
> code.
use HTML::Template;
------------------------------
Date: Thu, 19 Apr 2001 17:25:49 GMT
From: "smilepak" <smilepak@hotmail.com>
Subject: Re: if equal until loop exit?
Message-Id: <xcFD6.262$cM1.13640@newsread1.prod.itd.earthlink.net>
I have a perl question for ya. I have a data source file which is anywhere
from 25MB to 150MB. Data similar to the attached file. What I am trying to
do is to parse them into individual file.
If you can see (below) it is basically XML tags, but I want to grab
everything where t="222" until closing of </RES> and have that in one
file,
grab everything where t="585" up to closing of </RES> of that chunk and
place that into another file, etc. The value of T="?" will be derive from
a
list (which I might end up pushing it into an array). Anyone know of a
way.
Basically I have a list of array with value of "t=" and I want to parse
out
all chunk into their own file.
<RES name="www.oscar.com" t="585" total="43511">
<DATA v="1113" p="256">1</DATA>
<DATA v="438" p="101">2</DATA>
<DATA v="221" p="51">5</DATA>
<DATA v="1544" p="355">0</DATA>
<DATA v="3124" p="718">13</DATA>
<DATA v="2152" p="495">11</DATA>
<DATA v="1253" p="288">9</DATA>
<DATA v="197" p="45">6</DATA>
<DATA v="2553" p="587">17</DATA>
<DATA v="2667" p="613">20</DATA>
<DATA v="274" p="63">4</DATA>
<DATA v="2161" p="497">23</DATA>
<DATA v="498" p="114">3</DATA>
<DATA v="938" p="216">8</DATA>
<DATA v="2423" p="557">15</DATA>
<DATA v="1875" p="431">10</DATA>
<DATA v="2713" p="624">18</DATA>
<DATA v="2779" p="639">22</DATA>
<DATA v="3120" p="717">14</DATA>
<DATA v="2527" p="581">12</DATA>
<DATA v="2868" p="659">21</DATA>
<DATA v="543" p="125">7</DATA>
<DATA v="2539" p="584">16</DATA>
<DATA v="2991" p="687">19</DATA>
</RES>
<RES name="www.oscar.com" t="222" total="493660">
<DATA v="24156" p="489">11</DATA>
<DATA v="25559" p="518">15</DATA>
<DATA v="27382" p="555">17</DATA>
<DATA v="24892" p="504">19</DATA>
<DATA v="25005" p="507">10</DATA>
<DATA v="15499" p="314">4</DATA>
<DATA v="17154" p="347">3</DATA>
<DATA v="16677" p="338">22</DATA>
<DATA v="19988" p="405">16</DATA>
<DATA v="21477" p="435">8</DATA>
<DATA v="29359" p="595">18</DATA>
<DATA v="14204" p="288">23</DATA>
<DATA v="25897" p="525">12</DATA>
<DATA v="27438" p="556">13</DATA>
<DATA v="24947" p="505">9</DATA>
<DATA v="14040" p="284">0</DATA>
<DATA v="18711" p="379">7</DATA>
<DATA v="14473" p="293">1</DATA>
<DATA v="16024" p="325">5</DATA>
<DATA v="25349" p="513">14</DATA>
<DATA v="18913" p="383">6</DATA>
<DATA v="0" p="0">2</DATA>
<DATA v="20531" p="416">21</DATA>
<DATA v="25985" p="526">20</DATA>
</RES>
<RES name="www.oscar.com" t="346" total="43511">
<DATA v="1113" p="256">1</DATA>
<DATA v="438" p="101">2</DATA>
<DATA v="221" p="51">5</DATA>
<DATA v="1544" p="355">0</DATA>
<DATA v="3124" p="718">13</DATA>
<DATA v="2152" p="495">11</DATA>
<DATA v="1253" p="288">9</DATA>
<DATA v="197" p="45">6</DATA>
<DATA v="2553" p="587">17</DATA>
<DATA v="2667" p="613">20</DATA>
<DATA v="274" p="63">4</DATA>
<DATA v="2161" p="497">23</DATA>
<DATA v="498" p="114">3</DATA>
<DATA v="938" p="216">8</DATA>
<DATA v="2423" p="557">15</DATA>
<DATA v="1875" p="431">10</DATA>
<DATA v="2713" p="624">18</DATA>
<DATA v="2779" p="639">22</DATA>
<DATA v="3120" p="717">14</DATA>
<DATA v="2527" p="581">12</DATA>
<DATA v="2868" p="659">21</DATA>
<DATA v="543" p="125">7</DATA>
<DATA v="2539" p="584">16</DATA>
<DATA v="2991" p="687">19</DATA>
</RES>
>
>
------------------------------
Date: Thu, 19 Apr 2001 17:28:25 GMT
From: "smilepak" <smilepak@hotmail.com>
Subject: Re: if equal until loop exit?
Message-Id: <ZeFD6.286$cM1.14201@newsread1.prod.itd.earthlink.net>
I think i got it....
open (SRC, "$input");
while (defined ($line = <SRC>)) {
chomp($line);
if ($line =~ m/t\=\"(.*)\"\s+/) {
$parcode = $1;
print "$parcode\n";
}
if (exists $hash{$parcode}) {
open (DST, ">> $tmpdir/$accountid\-$parcode.dat") || die
"unable to create $accountid\-$code.dat\n";
print DST "$line\n";
if ($line =~ /\/RES/) {
close (DST);
}
}
}
close (SRC);
That should work, for anyone who trying to do the same thing as me...unless
someone got something better i am willing to use :)
"smilepak" <smilepak@hotmail.com> wrote in message
news:xcFD6.262$cM1.13640@newsread1.prod.itd.earthlink.net...
>
> I have a perl question for ya. I have a data source file which is
anywhere
> from 25MB to 150MB. Data similar to the attached file. What I am trying
to
> do is to parse them into individual file.
>
> If you can see (below) it is basically XML tags, but I want to grab
> everything where t="222" until closing of </RES> and have that in one
> file,
> grab everything where t="585" up to closing of </RES> of that chunk and
> place that into another file, etc. The value of T="?" will be derive from
> a
> list (which I might end up pushing it into an array). Anyone know of a
> way.
> Basically I have a list of array with value of "t=" and I want to parse
> out
> all chunk into their own file.
>
>
> <RES name="www.oscar.com" t="585" total="43511">
> <DATA v="1113" p="256">1</DATA>
> <DATA v="438" p="101">2</DATA>
> <DATA v="221" p="51">5</DATA>
> <DATA v="1544" p="355">0</DATA>
> <DATA v="3124" p="718">13</DATA>
> <DATA v="2152" p="495">11</DATA>
> <DATA v="1253" p="288">9</DATA>
> <DATA v="197" p="45">6</DATA>
> <DATA v="2553" p="587">17</DATA>
> <DATA v="2667" p="613">20</DATA>
> <DATA v="274" p="63">4</DATA>
> <DATA v="2161" p="497">23</DATA>
> <DATA v="498" p="114">3</DATA>
> <DATA v="938" p="216">8</DATA>
> <DATA v="2423" p="557">15</DATA>
> <DATA v="1875" p="431">10</DATA>
> <DATA v="2713" p="624">18</DATA>
> <DATA v="2779" p="639">22</DATA>
> <DATA v="3120" p="717">14</DATA>
> <DATA v="2527" p="581">12</DATA>
> <DATA v="2868" p="659">21</DATA>
> <DATA v="543" p="125">7</DATA>
> <DATA v="2539" p="584">16</DATA>
> <DATA v="2991" p="687">19</DATA>
> </RES>
> <RES name="www.oscar.com" t="222" total="493660">
> <DATA v="24156" p="489">11</DATA>
> <DATA v="25559" p="518">15</DATA>
> <DATA v="27382" p="555">17</DATA>
> <DATA v="24892" p="504">19</DATA>
> <DATA v="25005" p="507">10</DATA>
> <DATA v="15499" p="314">4</DATA>
> <DATA v="17154" p="347">3</DATA>
> <DATA v="16677" p="338">22</DATA>
> <DATA v="19988" p="405">16</DATA>
> <DATA v="21477" p="435">8</DATA>
> <DATA v="29359" p="595">18</DATA>
> <DATA v="14204" p="288">23</DATA>
> <DATA v="25897" p="525">12</DATA>
> <DATA v="27438" p="556">13</DATA>
> <DATA v="24947" p="505">9</DATA>
> <DATA v="14040" p="284">0</DATA>
> <DATA v="18711" p="379">7</DATA>
> <DATA v="14473" p="293">1</DATA>
> <DATA v="16024" p="325">5</DATA>
> <DATA v="25349" p="513">14</DATA>
> <DATA v="18913" p="383">6</DATA>
> <DATA v="0" p="0">2</DATA>
> <DATA v="20531" p="416">21</DATA>
> <DATA v="25985" p="526">20</DATA>
> </RES>
> <RES name="www.oscar.com" t="346" total="43511">
> <DATA v="1113" p="256">1</DATA>
> <DATA v="438" p="101">2</DATA>
> <DATA v="221" p="51">5</DATA>
> <DATA v="1544" p="355">0</DATA>
> <DATA v="3124" p="718">13</DATA>
> <DATA v="2152" p="495">11</DATA>
> <DATA v="1253" p="288">9</DATA>
> <DATA v="197" p="45">6</DATA>
> <DATA v="2553" p="587">17</DATA>
> <DATA v="2667" p="613">20</DATA>
> <DATA v="274" p="63">4</DATA>
> <DATA v="2161" p="497">23</DATA>
> <DATA v="498" p="114">3</DATA>
> <DATA v="938" p="216">8</DATA>
> <DATA v="2423" p="557">15</DATA>
> <DATA v="1875" p="431">10</DATA>
> <DATA v="2713" p="624">18</DATA>
> <DATA v="2779" p="639">22</DATA>
> <DATA v="3120" p="717">14</DATA>
> <DATA v="2527" p="581">12</DATA>
> <DATA v="2868" p="659">21</DATA>
> <DATA v="543" p="125">7</DATA>
> <DATA v="2539" p="584">16</DATA>
> <DATA v="2991" p="687">19</DATA>
> </RES>
>
>
>
>
>
> >
> >
>
>
>
------------------------------
Date: Thu, 19 Apr 2001 12:39:00 GMT
From: adelton@fi.muni.cz (Honza Pazdziora)
Subject: Re: Mailen mit Perl
Message-Id: <slrn9dtn33.28fu.adelton@nemesis.fi.muni.cz>
On Thu, 19 Apr 2001 13:33:19 +0200, Bastian Ballmann <ballmann@co-de.de> wrote:
> How can I send out a mail when e.g. the reading of some parameters wasnīt
> successful?
> There is a nice perl module out there isnīt it?
Yes, there should be one. The name ... ah, yes, Mail::Sender.
Hope this helps,
--
------------------------------------------------------------------------
Honza Pazdziora | adelton@fi.muni.cz | http://www.fi.muni.cz/~adelton/
.project: Perl, mod_perl, DBI, Oracle, auth. WWW servers, XML/XSL, ...
Petition for a Software Patent Free Europe http://petition.eurolinux.org
------------------------------------------------------------------------
------------------------------
Date: Thu, 19 Apr 2001 17:06:02 +0200
From: "Bastian Ballmann" <ballmann@co-de.de>
Subject: Re: Mailen mit Perl
Message-Id: <20010419.170600.1432114613.12719@pc035.co-de.de>
Im Artikel <slrn9dtn33.28fu.adelton@nemesis.fi.muni.cz> schrieb "Honza
Pazdziora" <adelton@fi.muni.cz>:
> On Thu, 19 Apr 2001 13:33:19 +0200, Bastian Ballmann <ballmann@co-de.de>
> wrote:
>
>> How can I send out a mail when e.g. the reading of some parameters
>> wasnīt successful?
>> There is a nice perl module out there isnīt it?
>
> Yes, there should be one. The name ... ah, yes, Mail::Sender.
>
> Hope this helps,
Yes that helped. Thanx. But I have still a little problem. Iīve read the
doc to Mail::Sender but I cant create a new Mailobject.
This is what I try to do: $mail = new Mail::Sender { smtp =>
'any.host.de', from => 'me@any.host.de' };
Could you examine whats wrong?
------------------------------
Date: Thu, 19 Apr 2001 17:40:31 +0200
From: "Bastian Ballmann" <ballmann@co-de.de>
Subject: Re: Mailen mit Perl
Message-Id: <20010419.174030.1172755590.12719@pc035.co-de.de>
Im Artikel <20010419.170600.1432114613.12719@pc035.co-de.de> schrieb
"Bastian Ballmann" <ballmann@co-de.de>:
> Im Artikel <slrn9dtn33.28fu.adelton@nemesis.fi.muni.cz> schrieb "Honza
> Pazdziora" <adelton@fi.muni.cz>:
>
>> On Thu, 19 Apr 2001 13:33:19 +0200, Bastian Ballmann
>> <ballmann@co-de.de> wrote:
>>
>>> How can I send out a mail when e.g. the reading of some parameters
>>> wasnīt successful?
>>> There is a nice perl module out there isnīt it?
>>
>> Yes, there should be one. The name ... ah, yes, Mail::Sender.
>>
>> Hope this helps,
>
> Yes that helped. Thanx. But I have still a little problem. Iīve read the
> doc to Mail::Sender but I cant create a new Mailobject. This is what I
> try to do: $mail = new Mail::Sender { smtp => 'any.host.de', from =>
> 'me@any.host.de' }; Could you examine whats wrong?
Iīve solved the problem by myself...
Iīve used the module strict but the new created object wasnīt set to my
or local... :-(
Stupid newbie fault <bg>
------------------------------
Date: Thu, 19 Apr 2001 12:37:39 -0400
From: david_kershaw@merck.com
Subject: Re: Makefile question.
Message-Id: <3ADF1453.B4CC17A7@merck.com>
Many times the CCFLAGS variable and others are defined in the Config.pm
module in your perl library. Atleast that is where Make gets those
variables most often. This module is created when the Perl installation
is built. There are a couple ways to affect this variable permanently or
temporarily. Temporarily you can use Config; and then localize the
global var $Config{'CCFLAGS'} to be whatever you want. However I have
not actually tried this.
Dave
The contents of this message express only the sender's opinion.
This message does not necessarily reflect the policy or views of
my employer, Merck & Co., Inc. All responsibility for the statements
made in this Usenet posting resides solely and completely with the
sender.
------------------------------
Date: Thu, 19 Apr 2001 09:02:24 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: mkdir and mv
Message-Id: <slrn9dtof0.2pd.tadmc@tadmc26.august.net>
Scott R. Godin <webmaster@webdragon.unmunge.net> wrote:
>In article <slrn9dtffp.5l9.abigail@tsathoggua.rlyeh.net>,
> abigail@foad.org (Abigail) wrote:
>
> | Perl does have a primitives to make directories and rename files though.
> | Why don't you use them?
>
>Oh fine, exploit the primitives.. You'll be sorry when they band
>together and overthrow the system.
When they overthrow the system, backticks, exec and pipe opens,
_then_ we'll really be backed into a corner...
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: 19 Apr 2001 17:58:04 +0100
From: nobull@mail.com
Subject: Re: mkdir and mv
Message-Id: <u98zkwg737.fsf@wcl-l.bham.ac.uk>
"Graham Wood" <graham.wood@iona.com> writes:
> Bastian Ballmann <ballmann@co-de.de> wrote in message
> news:20010419.115626.555996658.736@pc035.co-de.de...
> > Im Artikel <slrn9dtb85.gpv.rgarciasuarez@rafael.kazibao.net> schrieb
> > "Rafael Garcia-Suarez" <rgarciasuarez@free.fr>:
> >
> > > Bastian Ballmann wrote in comp.lang.perl.misc: } Hello everybody! :-)
> > > } Iīve another little question. I want to write a perl script to sort my
> > > } textfiles. To do this job the script has to make new directories and
> > > move } files into it.
> > > } I know that there is a shell module and I know that there is the exec
> > > } command, but I still canīt solve my stupid problem.
> > >
> > > No need to invoke external commands. Perl has mkdir() and rename()
> > > functions, that do what you want, and that are described in the perlfunc
> > > manual.
> >
> > Thanx a lot by now, the mkdir function is usefull and easy to use but
> > what shall I do with the rename function? I donīt want to rename those
> > files, I want to move them into my new directory...
>
> Renaming is synonymous with moving.
Provided, of course, both directories are on the same filesystem.
If not then see File::Copy.
--
\\ ( )
. _\\__[oo
.__/ \\ /\@
. l___\\
# ll l\\
###LL LL\\
------------------------------
Date: 19 Apr 2001 18:00:34 +0100
From: nobull@mail.com
Subject: Re: Old Chestnut? DATES!!
Message-Id: <u97l0gg6z1.fsf@wcl-l.bham.ac.uk>
"John Plaxton" <19wlr@globalnet.co.uk> writes:
> Has anyone got an easy way to return the first day of the
> Current/Next year. I'm using epoch second. I'd prefer it if it gave
> 12 midday if possible.
my $year=(localtime())[5]+1900; # Sic
use Time::Local;
my $midday_this_newyears_day = timelocal(0,0,12,1,0,$year);
my $midday_next_newyears_day = timelocal(0,0,12,1,0,$year+1);
print scalar localtime $midday_next_newyears_day," ",
scalar localtime $midday_this_newyears_day;
> I found some FAQ's on this a few months back but can't remember
> where.
FAQs are not the only manuals. Indeed FAQs really should only cover
stuff that can't be found by looking in the obvious places in the
reference manuals. You should have looked at time-related funtions in
perlfunc and time-related modules on CPAN.
--
\\ ( )
. _\\__[oo
.__/ \\ /\@
. l___\\
# ll l\\
###LL LL\\
------------------------------
Date: Thu, 19 Apr 2001 08:53:36 -0600
From: "Brian Lain" <brian@cs.wnmu.edu>
Subject: Owner problem
Message-Id: <9bmu5e$ihq$1@lynx.unm.edu>
Hi, I'm writing CGI scripts to make user directories and write an index.html
file in that directory. Everything works fine, but if I try to anything to
that file with FTP, I get a "Not owner" error. How can I make my CGI script
create the directory and file with the correct ownership?
Thank you,
Brian
------------------------------
Date: 19 Apr 2001 14:53:46 GMT
From: 208.155.52.2 [becky]
Subject: pdf optimization using pdfopt and a perl script
Message-Id: <9bmu5q6kjd@news1.newsguy.com>
I'm currently having problems with pdfopt (ghostscript 6.5). The largest file I am able to convert is 300K, I need to be able to optimize files as large as 15MB. Currently a perl script calls pdfopt. I've heard of bugs with pdfopt but have found no helpful information. Any information/advice on pdfopt or associated bugs would be appreciated. Thanks in advance.
==================================
Poster's IP address: 208.155.52.2
Posted via http://nodevice.com
Linux Programmer's Site
------------------------------
Date: Thu, 19 Apr 2001 12:16:29 -0500
From: Michael Wenzelmaier <michaelw@elkhart.net>
Subject: PERL Code Generator
Message-Id: <3ADF1D6D.EC5D68FF@elkhart.net>
"CodeCharge is a powerful code generator that helps web developers and
non-programmers create database-driven web applications in a matter of
hours. You may use it to easily create any types of web forms and grids,
such us User Registration Form for the web site or an Event List, or you
may generate full featured Employee Directories, Forums and Task
Management Systems up to advanced Online Auctions, Stores, Portals and
Intranets. In fact, CodeCharge comes with many of such solutions already
pre-built and you may easily customize them to your needs. CodeCharge
works by letting you select database fields to be included on each web
page and specifying how they should interact. It then generates
database-driven, dynamic websites in many server-programming languages
such as ASP, ColdFusion, JSP, PHP and Perl."
http://www.webprocenter.net/codecharge
------------------------------
Date: Thu, 19 Apr 2001 09:40:09 -0400
From: Andras Malatinszky <andras@mortgagestats.com>
Subject: Perl hashing algorithm description?
Message-Id: <3ADEEAB9.3F15CC83@mortgagestats.com>
Where can I find a good description of Perl's hashing algorithm?
What I am curious about is not how to use hashes but what Perl does to
the data I put in a hash, how the data is retrieved, etc. The camel book
has some vague references to buckets and the hashing algorithm being
inefficient when keys are similar, but I'd like to have something more
detailed (preferrably without having to sort through the source code).
Thanks,
Andras
------------------------------
Date: Thu, 19 Apr 2001 09:15:41 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: Perl hashing algorithm description?
Message-Id: <slrn9dtp7t.2ra.tadmc@tadmc26.august.net>
Andras Malatinszky <andras@mortgagestats.com> wrote:
>Where can I find a good description of Perl's hashing algorithm?
http://perl.plover.com/FakeHash/
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Thu, 19 Apr 2001 15:14:05 +0200
From: Martin Bower <Martin.Bower@ib.bankgesellschaft.de>
Subject: perl mail module and html
Message-Id: <3ADEE49D.79363802@ib.bankgesellschaft.de>
Hi,
I'm using the following module within Perl, and would like to send
formatted html as an email, so that it will show up in preview panes in
both Explorer and Netscape. At the moment it just prints text....any
ideas ?
p.s I'm using use Mail::Mailer;
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
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.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.
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 V10 Issue 720
**************************************