[17641] in Perl-Users-Digest
Perl-Users Digest, Issue: 5061 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Dec 8 06:05:43 2000
Date: Fri, 8 Dec 2000 03:05:09 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <976273508-v9-i5061@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Fri, 8 Dec 2000 Volume: 9 Number: 5061
Today's topics:
($fastest) ? "perl_on_Linux" : "perl_on_Windows" theredviper@my-deja.com
Re: ActivePerl Problem (Csaba Raduly)
Re: Beginner's question <bart.lateur@skynet.be>
Re: Displaying an image <ubl@schaffhausen.de>
Execute perl code enterred at run time? <mtx064@coventry.ac.uk>
Re: Execute perl code enterred at run time? <ron@savage.net.au>
Fail to use DBI::Proxy <john@imining.com.tw>
formresults at another page than cgi-page <harald@wanadoo.nl>
Re: formresults at another page than cgi-page (Sander van Gennip)
Re: MD5 module problems with Activestate Perl <mkuin@globalrangers.com>
Re: MIME::Lite message bounced by receiver server <olivier@aersoft.com>
Re: Object member variables <nickco3@yahoo.co.uk>
Re: Perl and Visual Studio (Csaba Raduly)
Re: Perl and Visual Studio <Petri_member@newsguy.com>
Re: Reading Data from STDIN (Joe Smith)
Re: Redirection? <nickco3@yahoo.co.uk>
Re: Regular expression question (Csaba Raduly)
Re: Regular expression question (Jim Ley)
Re: Sending email attachments <ron@savage.net.au>
Sending GSM sms (to proximus : Belgium) <apiron@ulb.ac.be>
Re: Simple Perl Http Server <ron@savage.net.au>
Sybase heterogeneous copy akluyskens@my-deja.com
Re: Win32::ODBC/MSAccess query rysmiel@my-deja.com
Re: Yesterdays Date <bart.lateur@skynet.be>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 08 Dec 2000 10:12:47 GMT
From: theredviper@my-deja.com
Subject: ($fastest) ? "perl_on_Linux" : "perl_on_Windows"
Message-Id: <90qc6t$5p4$1@nnrp1.deja.com>
This is sure to generate flame, but I have good intentions. <evil
grin>. I have just a general question that has probably already been
answered 100 times. I have my opinion on which is fastest (you
probably guessed), but is there one of these that is generally faster on
a certain platform with similiar hardware configurations or is it
primarily dependant on the type of processes being done? Just curious
as to what other people have noticed. And yes I realize that my
description of the operating systems is vague. tia.
- theredviper
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 8 Dec 2000 09:58:29 +0000 (UTC)
From: real.email@signature.this.is.invalid (Csaba Raduly)
Subject: Re: ActivePerl Problem
Message-Id: <Xns900465D01quuxi@194.203.134.135>
A million monkeys weren't enough! It took Joel Nelson
<joelnelson@home.com> on 08 Dec 2000 to produce
<3A307F69.138946D1@home.com>:
>alazarev1981@my-deja.com wrote:
>
>> I've installed ActivePerl 5.6.0.620 on my windows NT. I can run my
>> file (blah.cgi) from the command line and it works perfectly,
>> spits out the html taged code with no errors. However, when I try
>> to run that same script from an HTML form (action="blah.cgi") it
>> doesn't work. All I get is the .cgi file literally printed into my
>> browser.
>
>Your web server is misconfigured for running .cgi scripts.
>
>> I have the exact same files running and working on a unix server,
>> so I think the error is not in my code.
>
>Quite possibly.
>
>> I suspect the problem is in the first line of the .cgi file:
>> #!/usr/local/bin/perl
>
>Thats not the problem. However, when you get the web server
>configured correctly you will get 'Internal Server Error' because
>your shebang line '#!/usr/local/bin/perl' is indeed incorrect. It
>should point to your perl executable something like
>'#!d:\perl\bin\perl'. Note the slashes are windows style but just
>for that line.
>
That should either be #!d:\\perl\\bin\\perl or, more simply (gram?)
#!d:/perl/bin/perl
*My* perl.exe is d:/usr/bin/perl.exe
If you have perl.exe in the path, the simplest is #!perl (but that
wouldn't work on Unix, which is the system where the #! (shebang) line
really has a meaning.
Of course, none of this is a solution to the original problem (probably
a server misconfiguration)
--
Csaba Raduly, Software Developer (OS/2), Sophos Anti-Virus
mailto:csaba.raduly@sophos.com http://www.sophos.com/
US Support +1 888 SOPHOS 9 UK Support +44 1235 559933
... you'll be the first against the -pedantic -Wall -W
------------------------------
Date: Fri, 08 Dec 2000 10:57:50 GMT
From: Bart Lateur <bart.lateur@skynet.be>
Subject: Re: Beginner's question
Message-Id: <7hf13t8582oqu553kucuvhsnkrgmoaaar3@4ax.com>
Nick wrote:
>Is it possible to get a Perl interpreter to run on a Win98 machine so I
>don't have to go online to test scripts?
I'm sure that by "online", you mean "connected to the ouside world".
Yes. There are two Perl ports (virtually identical), ActiveState and
IndigoStar. The second one includes an Apache web server, so you get
your two things with just one install.
ActivePerl: <www.activestate.com>
IndigoPerl: <www.indigostar.com>
--
Bart.
------------------------------
Date: Fri, 08 Dec 2000 09:01:31 +0100
From: Malte Ubl <ubl@schaffhausen.de>
Subject: Re: Displaying an image
Message-Id: <3A30955C.66E2DCA1@schaffhausen.de>
Virgin News schrieb:
>
> I have created a script that reads from a .csv file to produce the data for
> the page and output it as html.
>
> i also want to use the club logo which is a jpg file.
>
> I have tried using the following line but it doesnt work.
>
> print "<img src='footie.jpg'>";
Although this has absolutely nothing to do with Perl what about this:
print '<img src="footie.jpg">'
->malte
------------------------------
Date: Fri, 8 Dec 2000 08:49:32 +0000
From: Dominic Hibbs <mtx064@coventry.ac.uk>
Subject: Execute perl code enterred at run time?
Message-Id: <Pine.OSF.3.91.1001208084303.22808G-100000@leofric>
Is it possible to execute perl code in a program which has received the
code from the user at run time.
About sixteen years ago I wrote a BASIC interpreter (in assembler) and
was persuaded by my son to include an EXEC function which took a
string
for argument and executed that string. If the string contained a line
number at the start the line was included on the fly and provided the
line number was higher than the currently executing line the program
continued with the new line inserted. I want to do the same thing in perl.
10 INPUT A$
20 EXEC A$
If the user types 30 PRINT "Hello World!"
Line 30 will be added to the program and Hello World! will be printed.
Without the line number, Hello World! will be printed but not added to
the program.
Less trivial you can write programs which will allow mathematical
functions to be enterred by the user and evaluated.
-----------------------------------------------------
Dominic Hibbs (Senior Lecturer)
School of Maths and Information Sciences
Coventry University
Priory Street
Coventry
CV1 5FB
02476 631313 Ext 7063
-----------------------------------------------------
------------------------------
Date: Fri, 8 Dec 2000 21:08:03 +1100
From: "Ron Savage" <ron@savage.net.au>
Subject: Re: Execute perl code enterred at run time?
Message-Id: <1y1Y5.4984$Vu1.94713@ozemail.com.au>
Look for 'eval' in the docs.
--
Cheers
Ron Savage
ron@savage.net.au
http://savage.net.au/index.html
Dominic Hibbs <mtx064@coventry.ac.uk> wrote in message
news:Pine.OSF.3.91.1001208084303.22808G-100000@leofric...
> Is it possible to execute perl code in a program which has received the
> code from the user at run time.
>
> About sixteen years ago I wrote a BASIC interpreter (in assembler) and
> was persuaded by my son to include an EXEC function which took a
> string
> for argument and executed that string. If the string contained a line
> number at the start the line was included on the fly and provided the
> line number was higher than the currently executing line the program
> continued with the new line inserted. I want to do the same thing in
perl.
>
> 10 INPUT A$
> 20 EXEC A$
>
> If the user types 30 PRINT "Hello World!"
>
> Line 30 will be added to the program and Hello World! will be printed.
> Without the line number, Hello World! will be printed but not added to
> the program.
>
> Less trivial you can write programs which will allow mathematical
> functions to be enterred by the user and evaluated.
>
> -----------------------------------------------------
> Dominic Hibbs (Senior Lecturer)
> School of Maths and Information Sciences
> Coventry University
> Priory Street
> Coventry
> CV1 5FB
> 02476 631313 Ext 7063
> -----------------------------------------------------
>
------------------------------
Date: Fri, 8 Dec 2000 16:33:06 +0800
From: "John" <john@imining.com.tw>
Subject: Fail to use DBI::Proxy
Message-Id: <90q6l7$rrh@netnews.hinet.net>
Hi all:
I want to access database(Access or SQL server) on NT from Linux through
DBI::Proxy.
I have setup ODBC DSN and run dbiproxy on NT.
The data source is
"DBI:Proxy:hostname=211.72.167.46;port=1234;dsn=dbi:ODBC:visitors"
I failed to call connect and the following error message was showed:
install_driver(Proxy) failed: Can't locate RPC/PlClient.pm in @INC (@INC
contains: /usr/local/lib/perl5/5.00557/i686-linux
/usr/local/lib/perl5/5.00557 /usr/loc
al/lib/perl5/site_perl/5.00557/i686-linux
/usr/local/lib/perl5/site_perl/5.00557
.) at /usr/local/lib/perl5/site_perl/5.00557/i686-linux/DBD/Proxy.pm line
28.
BEGIN failed--compilation aborted at
/usr/local/lib/perl5/site_perl/5.00557/i686
-linux/DBD/Proxy.pm line 28.
Perhaps a module that DBD::Proxy requires hasn't been fully installed
at insert_dbi4.pl line 13
Why?
Thanks in advance.
John Hsieh
john@imining.com.tw
------------------------------
Date: Fri, 8 Dec 2000 11:46:41 +0100
From: "Harald ter Haar" <harald@wanadoo.nl>
Subject: formresults at another page than cgi-page
Message-Id: <3a30bc2e$0$7996@reader5>
Hello everyone,
My form leads to a cgi-script wich is at an other web-domain. This is
because my host doesn't support cgi-scripts. Now, I want the 'print'-result
of the form , (for example "Thank you for using my form, klick here to go
back") not on de cgi-page itself, but at a separated html-page of the domain
where my form stays.
So for example:
"http://home.domainname1.com/form.html" leads to
"http://home.domainname2.com/form.cgi"
Then: formresults at
"http://home.domainname1.com/formresult.html"
Note: I want this to avoid the commercial-popups wich appear by giving
commands in de cgi to show something in html. I hope I made myself
clear enough that you can help me.
Thanks,
Harald
------------------------------
Date: Fri, 08 Dec 2000 11:03:09 GMT
From: sander@veenhoven.com (Sander van Gennip)
Subject: Re: formresults at another page than cgi-page
Message-Id: <3a30bf58.10967941@news.xs4all.nl>
On Fri, 8 Dec 2000 11:46:41 +0100, Harald ter Haar wrote:
>Hello everyone,
>
>My form leads to a cgi-script wich is at an other web-domain. This is
>because my host doesn't support cgi-scripts. Now, I want the 'print'-result
>of the form , (for example "Thank you for using my form, klick here to go
>back") not on de cgi-page itself, but at a separated html-page of the domain
>where my form stays.
>So for example:
>"http://home.domainname1.com/form.html" leads to
>"http://home.domainname2.com/form.cgi"
>Then: formresults at
>"http://home.domainname1.com/formresult.html"
>
>Note: I want this to avoid the commercial-popups wich appear by giving
>commands in de cgi to show something in html. I hope I made myself
>clear enough that you can help me.
>
>Thanks,
>Harald
I am not sure if this is helpful, but you could try to have the script
return a page that contains:
<script>
window.open("http://home.domainname1.com/formresult.html");
</script>
This will only work with JS enabled though. Problem is that the script
is not allowed to open files on a different site. It might be a better
solution to just have the script generate the formresult page.
------------------------------
Date: Fri, 8 Dec 2000 09:55:21 +0100
From: "Mark Kuin" <mkuin@globalrangers.com>
Subject: Re: MD5 module problems with Activestate Perl
Message-Id: <90q7m0$jrr$1@news1.xs4all.nl>
I posted this suggestion because I had the same problems as you have.
My problems were solved after the ppm install thing.
I'm using the same version as you are using (activestate perl build 618), so
it might also help you...
------------------------------
Date: Fri, 08 Dec 2000 10:18:22 GMT
From: Olivier Dupouy <olivier@aersoft.com>
Subject: Re: MIME::Lite message bounced by receiver server
Message-Id: <3A30B65F.BE526F21@aersoft.com>
Peter Sundstrom wrote:
> Olivier Dupouy <olivier@aersoft.com> wrote in message
> news:3A2FC881.BD66C595@aersoft.com...
> > I am using MIME::Lite to send messages. That wotks pretty well exept
> > when I send it to special email addresses where the server is checking
> > the sender id.
> > In the mail I am sending, Lite fill the field Return-path by
> > myusername@mymachine : Return-path: olivier@mars --> mars is my
> > machine
> > It should fill it by olivier@aersoft.ie, what can I do to do this??
> >
> > That's the kind of messages the receiver demon reply me:
> >
> > Your message cannot be delivered to the following recipients:
> > Recipient address: friend@host1.com
> > Reason: Remote SMTP server has rejected address
> > Diagnostic code: smtp; 504 <olivier@mars>: Sender address rejected:
> > need fully-qualified address
> >
> > or
> >
> > Your message cannot be delivered to the following recipients:
> > Recipient address: friend@host2.com
> > Reason: Message rejected; bad return address.
> > Diagnostic code: smtp; 501 <olivier@mars>... Sender domain must exist
>
> Show us the relevant code you are using. I would be very surprised if
> MIME::Lite is stripping the domain from the sender address.
Then, here is the relevant code:
#!/apps/bin/perl -w
use strict;
use MIME::Lite;
my $from = 'Olivier Dupouy <olivier.dupouy@aersoft.ie>';
my $to = 'Oliver <odupouy@hotmail.com>';
my $subject = "new try";
my $msg = MIME::Lite->new(
FromSender => "$from",
From => "$from",
Subject => "$subject",
Sender => "$from",
Reply => "$from",
To => "$to",
Type => 'TEXT',
Data => "Here's my text"
);
$msg->send;
}
If I send the message to my hotmail account, here is what hotmail receive:
From olivier@mars Fri Dec 08 01:58:42 2000
Received: from [194.125.107.131] by hotmail.com (3.2) with ESMTP id
MHotMailBBF9FB7400424004310BC27D6B8385840; Fri Dec 08 01:57:09 2000
Received: from mars.aersoft.ie (mars)
by pluto.aersoft.ie (Sun Internet Mail Server sims.3.2.1998.01.03.00.26)
with SMTP id <0G58009LKU6CEK@pluto.aersoft.ie> for odupouy@hotmail.com;
Fri,
8 Dec 2000 09:54:12 +0000 (GMT)
Received: by mars.aersoft.ie (SMI-8.6/SMI-SVR4) id KAA01618; Fri,
08 Dec 2000 10:01:11 +0000 (GMT)
Date: Fri, 08 Dec 2000 10:01:11 +0000 (UT)
From: Olivier Dupouy <olivier.dupouy@pluto.aersoft.ie>
Subject: new try
Sender: Olivier Dupouy <olivier.dupouy@pluto.aersoft.ie>
To: Oliver <odupouy@hotmail.com>
Message-id: <200012081001.KAA01618@mars.aersoft.ie>
MIME-version: 1.0
X-Mailer: MIME::Lite 2.106 (B2.11; Q2.03)
Content-type: text/plain
Content-disposition: inline
Content-transfer-encoding: binary
Here's my text
The probleme seems to be in the first line of the code: olivier@mars instead
of olivier.dupouy@aersoft.ie
In my code, if I replace $msg->send; by $msg->print; , here is what I get on
my Terminal:
olivier on mars:97> email.pl
Content-Disposition: inline
Content-Length: 14
Content-Transfer-Encoding: binary
Content-Type: text/plain
MIME-Version: 1.0
X-Mailer: MIME::Lite 2.106 (B2.11; Q2.03)
Date: Fri, 8 Dec 2000 10:16:03 UT
From: Olivier Dupouy <olivier.dupouy@aersoft.ie>
Subject: new try
Sender: Olivier Dupouy <olivier.dupouy@aersoft.ie>
To: Oliver <odupouy@hotmail.com>
What is strange is that I don't find any olivier@mars in the above lines!
That's probably Sendmail that manipulate emails addresses and instert
olivier@mars.
Thinks to anybody who have a clue to the mysterious problem
Olivier
------------------------------
Date: Fri, 08 Dec 2000 10:53:18 +0000
From: Nick Condon <nickco3@yahoo.co.uk>
Subject: Re: Object member variables
Message-Id: <3A30BD9E.D3EC8D06@yahoo.co.uk>
Jan van Mansum wrote:
> Thanks. I take it $self is a reference to a hash (the object), so the member
> variables and their values are just name/value pairs on this hash. I *think* I
> am *beginning* to understand.
That's right. Objects are almost always represented a hash, with attributes as
keys. The 'bless' function labels the hash as an object.
Officially you can bless (the reference to) any kind of data structure and make it
an object, but best not to worry about that until you've got the hang of doing it
with hashes.
------------------------------
Date: Fri, 8 Dec 2000 09:51:13 +0000 (UTC)
From: real.email@signature.this.is.invalid (Csaba Raduly)
Subject: Re: Perl and Visual Studio
Message-Id: <Xns900466645quuxi@194.203.134.135>
A million monkeys weren't enough! It took "Thomas E Nowak Jr"
<ten@bluemoon.net> on 08 Dec 2000 to produce
<SzWX5.25$vL_3.6488378@news.randori.com>:
>I just downloaded ActivePerl-5.6.0.620 and already own Visual Studio
>products Visual Basic 6 and Visual J 6. When I try to install Perl, I
>receive:
>
>If you have a development environment (e.g. Visual Studio) that you
>wish to use with Perl, you should ensure that your environment (e.g.
>%LIB% and %INCLUDE%) is set before installing.
>
>Proceed? [y]
>
>I do have Visual Studio, but I really dont know what this statement is
>asking me. Any Ideas ? Please help.
>
It means that the install procedure takes a note of the environment
when it sets up Perl.
The simplest way is to open a command prompt, run VCVARS32.BAT (this
will set the environment variables INCLUDE and LIB, among others), the
run the installation *from the same command wndow*.
HTH
--
Csaba Raduly, Software Developer (OS/2), Sophos Anti-Virus
mailto:csaba.raduly@sophos.com http://www.sophos.com/
US Support +1 888 SOPHOS 9 UK Support +44 1235 559933
... you'll be the first against the -pedantic -Wall -W
------------------------------
Date: 8 Dec 2000 02:12:45 -0800
From: Petri Oksanen <Petri_member@newsguy.com>
Subject: Re: Perl and Visual Studio
Message-Id: <90qc6t0fdl@edrn.newsguy.com>
In article <SzWX5.25$vL_3.6488378@news.randori.com>, "Thomas says...
> I just downloaded ActivePerl-5.6.0.620 and already own
> Visual Studio products Visual Basic 6 and Visual J 6.
> When I try to install Perl, I receive:
>If you have a development environment (e.g. Visual Studio) that you
>wish to use with Perl, you should ensure that your environment (e.g.
>%LIB% and %INCLUDE%) is set before installing.
You can ignore this, since you don't have Visual C/C++ installed.
If you would've had VC installed, Perl would use it to compile modules with C
components, if you would download any module from CPAN that requires it.
Petri Oksanen
------------------------------
Date: 8 Dec 2000 08:34:46 GMT
From: inwap@best.com (Joe Smith)
Subject: Re: Reading Data from STDIN
Message-Id: <90q6f6$1t1t$1@nntp1.ba.best.com>
In article <3A2E7F53.8D1CDD1B@gte.net>, Bill Nelson <isstb@flanet.com> wrote:
>If I do not know how big data coming in from STDIN is, how can I use the
>read() command (or other similar command) to get the data from STDIN?
>
>Note: I cannot use a while(<>) or @array = <STDIN> because I do not see
>end of file in the data.
If you don't see the end of file, then there is a bug in whatever is
sending you data. There is no solution unless the sender of data
provides a byte count, explictly sends an eof indication, or uses
a predefined string to signal end-of-file.
>I am passing data from a web page form to a port on a server which is
>not running a web server. I have a perl script read the data from STDIN
>and this is where I am having problems. If I specify a length of that
>data I can read it just fine. Problem is that I do not know the length
>of the data so I cannot do this accurately.
The data from the web page form was sent by a browser (or other HTTP
client). The browser/client provides the Content-Length: header to
your program; it is your responsibility to use that value appropriately.
Have you tried using LWP? You can use it to create to objects; one
to read the data from the browser and the other to send the data to
the other server. LWP handles end-of-data properly.
-Joe
--
See http://www.inwap.com/ for PDP-10 and "ReBoot" pages.
------------------------------
Date: Fri, 08 Dec 2000 10:58:06 +0000
From: Nick Condon <nickco3@yahoo.co.uk>
Subject: Re: Redirection?
Message-Id: <3A30BEBE.4FC087B@yahoo.co.uk>
EnIgMaBoM wrote:
> I have just written an anonymous message board script for my site, It works
> quite nicely, It takes the input from a form, and plops it out into a html
> file. Unfotunately, I need the script to re-direct it to the msg board
> file...any ideas?
perldoc -f open
------------------------------
Date: Fri, 8 Dec 2000 10:12:02 +0000 (UTC)
From: real.email@signature.this.is.invalid (Csaba Raduly)
Subject: Re: Regular expression question
Message-Id: <Xns900466D72quuxi@194.203.134.135>
A million monkeys weren't enough! It took "Walter Zackery" <Please_
Respond_ Within@Newsgroup.com> on 07 Dec 2000 to produce
<90ov9o$d914$1@newssvr06-en0.news.prodigy.com>:
>var Match = 'The dog was dog tired.'.replace(/dog tired/g,"").match(/dog/g);
>
Can't modify subroutine entry in scalar assignment at q.pl line 1, near ");"
What language was that ? Not Perl, that's for sure.
--
Csaba Raduly, Software Developer (OS/2), Sophos Anti-Virus
mailto:csaba.raduly@sophos.com http://www.sophos.com/
US Support +1 888 SOPHOS 9 UK Support +44 1235 559933
... you'll be the first against the -pedantic -Wall -W
------------------------------
Date: Fri, 08 Dec 2000 10:46:16 GMT
From: jim@jibbering.com (Jim Ley)
Subject: Re: Regular expression question
Message-Id: <3a30bbd3.3051989@news.dircon.co.uk>
On Fri, 8 Dec 2000 10:12:02 +0000 (UTC),
real.email@signature.this.is.invalid (Csaba Raduly) wrote:
>A million monkeys weren't enough! It took "Walter Zackery" <Please_
>Respond_ Within@Newsgroup.com> on 07 Dec 2000 to produce
><90ov9o$d914$1@newssvr06-en0.news.prodigy.com>:
>
>>var Match = 'The dog was dog tired.'.replace(/dog tired/g,"").match(/dog/g);
>>
>
>Can't modify subroutine entry in scalar assignment at q.pl line 1, near ");"
>
>What language was that ? Not Perl, that's for sure.
The post seems to be cross-posted between comp.lang.javascript, and
comp.lang.perl.misc, the above was of course javascript... weird
cross-post.
Jim.
--
FAQ: http://jibbering.com/faq/
Old FAQs: http://jibbering.com/faq/old/
------------------------------
Date: Fri, 8 Dec 2000 21:09:32 +1100
From: "Ron Savage" <ron@savage.net.au>
Subject: Re: Sending email attachments
Message-Id: <qz1Y5.4986$Vu1.95545@ozemail.com.au>
Since this is a Perl newsgroup,
http://savage.net.au/Perl-tutorials.html#tut-2
--
Cheers
Ron Savage
ron@savage.net.au
http://savage.net.au/index.html
Ryan Hubbard <pastry1001@aol.com> wrote in message
news:t30ouc9nm5hhc0@corp.supernews.com...
> I would like to automate some email by sending attachments. Which program
> should I use on a unix platform. Can Pine do it? Should I use Mutt?
> Which should I use and how should I go about doing it?
> Thanks
>
> --
> Posted via CNET Help.com
> http://www.help.com/
------------------------------
Date: Fri, 08 Dec 2000 11:58:28 +0100
From: Anthony PIRON <apiron@ulb.ac.be>
Subject: Sending GSM sms (to proximus : Belgium)
Message-Id: <3A30BED4.3A21656E@ulb.ac.be>
Hi all,
I wrote a little script to send sms to my GSM. This script connect to
http://application.proximus.be/WMS/SilverStream/Pages/pgSMS.html
and setup the correct parameters to send message.
My problem is the following : after the data post, I receive the main
page and not the
page showing the good/bad sms send state (neverthless the sms is send).
Is there a solution to my problem ?
Thanks.
The script :
use IO::Socket;
my($host,$file, $param, $prefix, $telnum, $msg);
## prefix telnum msg
unless (@ARGV > 2) { die "usage: $0 prefix telnum msg ..." }
if ($ARGV[0] eq "0474") {$prefix = "0"}
elsif ($ARGV[0] eq "0475") {$prefix = "1"}
elsif ($ARGV[0] eq "0476") {$prefix = "2"}
elsif ($ARGV[0] eq "0477") {$prefix = "3"}
elsif ($ARGV[0] eq "0478") {$prefix = "4"}
elsif ($ARGV[0] eq "0479") {$prefix = "5"}
else {die "Invalid prefix"}
$telnum = $ARGV[1];
$msg = $ARGV[2];
$msg =~ s/\W+/+/g;
$param = "?language=fr" . "&S26_=$prefix" . "&S28_=$telnum" .
"&S32_=$msg" . "&AgEvtSrc=S38_" ;
## print $param . "\n";
$file = "/WMS/SilverStream/Pages/pgSMS.html" . "$param";
print "\nAppel : " . $file . "\n\n" . "Message : " . $msg . "\n";
connect_addr("application.proximus.be", $file);
## connect_addr(host, file1, file2, ...)
sub connect_addr {
my $host = shift(@_);
my $EOL = "\015\012";
my $BLANK = $EOL x 2;
foreach $document ( @_ )
{
my $remote = IO::Socket::INET->new( Proto => "tcp",
PeerAddr => $host,
PeerPort => "http(80)",
);
unless ($remote) { die "cannot connect to http daemon on $host" }
$remote->autoflush(1);
print $remote "POST $document HTTP/1.0" . $BLANK;
while ( <$remote> ) { print }
close $remote;
}
}
--
Anthony
------------------------------
Date: Fri, 8 Dec 2000 21:11:53 +1100
From: "Ron Savage" <ron@savage.net.au>
Subject: Re: Simple Perl Http Server
Message-Id: <DB1Y5.4992$Vu1.95676@ozemail.com.au>
http://stockholm.ptloma.edu/httpi/
(from my page: http://savage.net.au/Links.html )
--
Cheers
Ron Savage
ron@savage.net.au
http://savage.net.au/index.html
Stuart Lowes <stuart@zerostate.co.uk> wrote in message
news:iPWX5.2414$tR1.44934@news2-win.server.ntlworld.com...
> I am looking for guidance in how to write a simple http server for *small
> part* of my university project. I need this simple server because I will
be
> adminstering apache and other ISP related facilties from the web, similar
to
> what webmin does.
>
> Does anyone have any http server perl scripts (i really want to stick to
> perl)?
> Or can anyone point me in the right direction. I know there are perl
httpd
> servers out there and I obviously don't want to reinvent the wheel.
>
> Thanks,
>
> Stuart
>
>
>
------------------------------
Date: Fri, 08 Dec 2000 10:51:10 GMT
From: akluyskens@my-deja.com
Subject: Sybase heterogeneous copy
Message-Id: <90qeet$7aa$1@nnrp1.deja.com>
Hello,
Are there any sybase system admin out here? I have to perform a system
copy of a large sybase dataserver running on HP_UX to an AIX system.
Does someone know if there are any (perl)tools availbale to do so or if
sybase provides a decent method to perform such copies (they don't have
exports like Oracle). I looked on the internet, posted a msg to the
sybase newsgroup (still no answer). I know this is not really the place
to post such messages but some Perl users could also be Sybase
sysadmins.
Any help is welcome.
?Is bcp the only way to transfer data to other platforms because it is
very slow, you have to do it table by table (OK it's scriptable) and
when you write it directly to pipes over a slow network the transaction
has a 75% chance of failure.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 08 Dec 2000 09:31:52 GMT
From: rysmiel@my-deja.com
Subject: Re: Win32::ODBC/MSAccess query
Message-Id: <90q9q9$48n$1@nnrp1.deja.com>
In article <3A3000F1.FCAF4DB7@surfaid.org>,
Greg Griffiths <greg2@surfaid.org> wrote:
> why would you want to do this, I doubt that there would be any
advantage
> over recoding it your CGI script.
The database with which I am working has about four years' worth of
very complex queries, and my co-workers have strong preferences for
keeping and using these which I'm not in a position to overrule.
>
> rysmiel@my-deja.com wrote:
>
> > Is it possible to call an existing queryin an MSAccess database from
a
> > perl script using Win32::ODBC, and if so what is the format ?
> >
> > Thanks in advance,
> >
> > E
> >
> > Sent via Deja.com http://www.deja.com/
> > Before you buy.
>
>
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 08 Dec 2000 10:53:00 GMT
From: Bart Lateur <bart.lateur@skynet.be>
Subject: Re: Yesterdays Date
Message-Id: <r2f13tgge59h21gb09gp1otn6l83vk2els@4ax.com>
Martien Verbruggen wrote:
>> (my $day,my $month,my $year) = (localtime(time))[3,4,5];
>> gives me todays date but what's the most simple way to get yesterdays date
>> in the same format?
>
>my ($day, $month, $year) = (localtime(time - 86400))[3,4,5];
>
>And no, this doesn't give anyone any problems around DST changes.
Eh? It doesn't?
Because of DST, there are days with only 23 hours in 'em, aren't there?
What if you do this test, ooh, 15 minutes into the next day? You'll get
the day it was 24 hours ago, 45 minutes before midnight then. That is 2
days ago.
Odd chance, I know.
--
Bart.
------------------------------
Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 16 Sep 99)
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.
| NOTE: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.
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 V9 Issue 5061
**************************************