[25783] in Perl-Users-Digest
Perl-Users Digest, Issue: 8022 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Apr 28 03:05:54 2005
Date: Thu, 28 Apr 2005 00:05:06 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Thu, 28 Apr 2005 Volume: 10 Number: 8022
Today's topics:
Re: Adding Perl Core functions <nospam-abuse@ilyaz.org>
Re: Client does not support authentication protocol req <pilkowsk@informatik.uni-marburg.de>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <hackeras@gmail.com>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <mark.clementsREMOVETHIS@wanadoo.fr>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <tadmc@augustmail.com>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <tadmc@augustmail.com>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <sbryce@scottbryce.com>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <hackeras@gmail.com>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <pilkowsk@informatik.uni-marburg.de>
Re: converting games.pl(cgi.pm) => games.pl (html::temp <mark.clementsREMOVETHIS@wanadoo.fr>
Extracting the link text (Fritz Bayer)
Net::SMTP in a chroot jail - can't initialise the conne <pete@philfam.co.uk>
Re: Net::SMTP in a chroot jail - can't initialise the c <glex_nospam@qwest.invalid>
Re: Net::SMTP in a chroot jail - can't initialise the c <apeiron+usenet@coitusmentis.info>
Re: one-time and one-line programs <groleau+news@freeshell.org>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 28 Apr 2005 02:40:54 +0000 (UTC)
From: Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: Adding Perl Core functions
Message-Id: <d4pifm$30ed$1@agate.berkeley.edu>
[A complimentary Cc of this posting was sent to
Guenther Sohler
<guenther.sohler@newlogic.com>], who wrote in article <pan.2005.04.25.05.09.30.716067@newlogic.com>:
> Unfortunately the XS Approach did not really fit into my concept.
> Using XS sounded like creating an extra, external Module for perl.
Not necessarily. First, debug it as an external module. Then, when
things work, compile the C part into your executable. Eval the Perl
part (if needed) from your start-perl shim before doing perl_run()
(sp?).
But usually no Perl part is required at all; see how UNIVERSAL::*
methods are implemented in Perl proper.
Hope this helps,
Ilya
------------------------------
Date: Thu, 28 Apr 2005 02:07:02 +0200
From: Fabian Pilkowski <pilkowsk@informatik.uni-marburg.de>
Subject: Re: Client does not support authentication protocol requested by server;
Message-Id: <3danllF6slst2U1@individual.net>
* Nikos schrieb:
> Mark Clements wrote:
>
>> Do you *ever* try google for your questions, or is this newsgroup your
>> first port of call? Do you expect everyone else to read the
>> documentation for you?
>
> I did try somethign that i found on google but it did not correct the
> problem.
Ok, you have read something you found on google about this problem.
Hence, you know that MySQL 4.1 and up uses a new password hashing
algorithm, do you? And, why not looking into the MySQL docs when your
search at google fails? Please, read your problem's solution at
http://dev.mysql.com/doc/mysql/en/old-client.html
>
> Also some other stuff i found i didnt understand them, so i though it
> was a good idea to ask here for a more detailed explanation.
I think, it is a good idea to search for more detailed explanations
using google -- particularly, before starting a new thread here. I
suggest you try out every solution proposed on the website above,
there're just four of it.
Btw, I have had this problem a few days ago as a result of upgrading my
MySQL server too. And I can guarantee that the first solution mentioned
there is the easiest way to be satisfied, IMHO -- ok, a nice (closed
source) freeware tool I used on my windows box for many years to manage
the database wasn't updatable, but MySQL itself provides a small tool
with a similar functionality -- hence, it doesn't matter to me ;-)
regards,
fabian
------------------------------
Date: Thu, 28 Apr 2005 01:27:42 +0300
From: Nikos <hackeras@gmail.com>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <d4p3kr$emg$2@nic.grnet.gr>
Mark Clements wrote:
Ok please suggest something to the problem i posted and i try to fix it
and come up with a specific question.
------------------------------
Date: Thu, 28 Apr 2005 00:40:23 +0200
From: Mark Clements <mark.clementsREMOVETHIS@wanadoo.fr>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <427014dc$0$25041$8fcfb975@news.wanadoo.fr>
Nikos wrote:
> Mark Clements wrote:
>
> Ok please suggest something to the problem i posted and i try to fix it
> and come up with a specific question.
You really couldn't make this up....
Here is the information you give:
>Hello, iam tryign to convert another script to htm;::template but iam
>having some problems:
and
>At that time yes i would like a little spoonfeeding but the template
>its done(i guess its correct since now i have problem with MySQL too
>and i cant test it), the only help i need is with the snippet of
>games.pl
(I have already (in other threads) suggested one way in which MySQL
problems can be diagnosed, but since you didn't seem to be interested in
following my advice then, I doubt if you will now, and so I won't
repeat myself).
Anyway (in no particular order):
1. you haven't told us what the expected behaviour is
2. you haven't told us what the *actual* behaviour is.
3. you haven't read the posting guidelines (as you have been asked to do
on several occasions).
4. you haven't broken the problem down into the smallest possible piece
of code that demonstrates the issue.
5. you haven't told us where the failure is.
6. in short, you have given us *nothing* to go on.
Do you really expect us to set up an environment like yours, install
your script, run it, and then work through all *your* problems *ourselves*?
I don't know whether to laugh or cry. Why do I feel like I'm beating my
head against a brick wall?
Mark
------------------------------
Date: Wed, 27 Apr 2005 17:51:33 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <slrnd705rl.6ti.tadmc@magna.augustmail.com>
Nikos <hackeras@gmail.com> wrote:
> Ok please suggest something
Give up on programming, you are not suited for it.
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Wed, 27 Apr 2005 17:55:43 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <slrnd7063f.6uu.tadmc@magna.augustmail.com>
Mark Clements <mark.clementsREMOVETHIS@wanadoo.fr> wrote:
> Why do I feel like I'm beating my
> head against a brick wall?
Because you are. :-(
(It will feel really good when you stop though. :-)
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Wed, 27 Apr 2005 16:59:07 -0600
From: Scott Bryce <sbryce@scottbryce.com>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <pumdnROvVcSkhO3fRVn-rQ@comcast.com>
Nikos wrote:
> Ok please suggest something to the problem i posted and i try to fix it
> and come up with a specific question.
Read the documentation for HTML:Template. The answer to your question is
there. Look for the section on TMPL_LOOP.
http://search.cpan.org/~samtregar/HTML-Template-2.7/Template.pm
It looks like you are trying to print the data rather than pass it to
the template. You want to pass the data to the template, then print the
template. The docs for HTML::Template will explain how to do this.
I am not going to take the time to try to re-create your database on my
system to re-write your code so it works.
If there is something specific about the documentation for the TMPL_LOOP
tag in the HTML::Template docs, you can ask.
------------------------------
Date: Thu, 28 Apr 2005 02:02:54 +0300
From: Nikos <hackeras@gmail.com>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <d4p5ms$gfv$1@nic.grnet.gr>
Tad McClellan wrote:
> Give up on programming, you are not suited for it.
Iam just trying all these days to convert my cgi.pm database to a
html::template.
Its just my personal web page, iam not a professional programmer as you
already figure out yoursleves. ;-)
------------------------------
Date: Thu, 28 Apr 2005 02:28:46 +0200
From: Fabian Pilkowski <pilkowsk@informatik.uni-marburg.de>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <3daou7F6ftg7fU1@individual.net>
* Nikos schrieb:
> Mark Clements wrote:
>>
>> So what you are saying is: despite all the help you were given with a
>> pretty much identical problem over quite a long period of time, by a
>> number of very patient posters (I've lost all patience, as you can tell)
>> you have learnt nothing and want to be spoon-fed the entire development
>> process *again*?
>
> You have right to feel that way you are feeling but unfortunately i am
> again stuck.
>
> At that time yes i would like a little spoonfeeding but the template its
> done(i guess its correct since now i have problem with MySQL too and i
> cant test it), the only help i need is with the snippet of games.pl
Whence you know your script rocks the boat since you cannot testing it?
Why not fixing your MySQL server first?
Why not using an alternative data source for testing (when no database
is available for the moment)?
regards,
fabian
------------------------------
Date: Thu, 28 Apr 2005 08:14:54 +0200
From: Mark Clements <mark.clementsREMOVETHIS@wanadoo.fr>
Subject: Re: converting games.pl(cgi.pm) => games.pl (html::template)
Message-Id: <42707f5f$0$25046$8fcfb975@news.wanadoo.fr>
Nikos wrote:
> Tad McClellan wrote:
>
>> Give up on programming, you are not suited for it.
>
>
> Iam just trying all these days to convert my cgi.pm database to a
> html::template.
>
> Its just my personal web page, iam not a professional programmer as you
> already figure out yoursleves. ;-)
>
>
Most of us *are* professional programmers. The amount of work you want
doing for you exceeds what can reasonably be expected of us: this has
been pointed out by several posters on several occasions. You are being,
quite simply, rude. In effect, your problems (or what we can divine of
them using our telepathic powers, since you never state them clearly),
are very probably quite simple to solve, but you have refused to attempt
any diagnosis despite the myriad methods that have been suggested to
you. I reckon another two hours should do it: you can have a special
rate of 147EUR per hour, though I'll guess I've already spent an hour
typing replies to you and sobbing quietly in the corner. Asking me for
more help implies acceptance of these terms.
Mark
------------------------------
Date: 28 Apr 2005 00:04:25 -0700
From: fritz-bayer@web.de (Fritz Bayer)
Subject: Extracting the link text
Message-Id: <a9c0aa9e.0504272304.2499a941@posting.google.com>
Hi,
I would like to extract all the links from a html page, which I store
in a string variable.
For each link, I would also like to print out the link text, however,
omitting ALL possible tags in which the text could be embedded.
I'm looking for a regular expression, which does just that. Can
somebody help me out?
Fritz
------------------------------
Date: Wed, 27 Apr 2005 23:34:16 +0100
From: Pete Phillips <pete@philfam.co.uk>
Subject: Net::SMTP in a chroot jail - can't initialise the connection
Message-Id: <42701368$0$540$ed2619ec@ptn-nntp-reader03.plus.net>
Hi
I am running apache2 in a chroot jail, with modperl
Apache/2.0.52 (Unix) mod_chroot/0.3 mod_perl/1.999.22 Perl/v5.8.0
I can't get Net::SMTP to set up a connection to my mailserver -
$smtp = Net::SMTP->new('mailhost.domain');
print STDOUT $smtp->domain,"\n";
$smtp->quit;
just gives me :
[error] Can't call method "domain" without a package
or object reference at /perl/www-feedback.cgi line 100.\n
Ruuning the same code as a stand alone perl script works OK.
I have etc/hosts and resolve.conf in the chroot jail, as well as
libresolv.so.2
Any ideas, or do you require further information ?
Cheers,
Pete
------------------------------
Date: Wed, 27 Apr 2005 18:54:08 -0500
From: "J. Gleixner" <glex_nospam@qwest.invalid>
Subject: Re: Net::SMTP in a chroot jail - can't initialise the connection
Message-Id: <zCVbe.1978$d93.1226@news.uswest.net>
Pete Phillips wrote:
> I can't get Net::SMTP to set up a connection to my mailserver -
>
> $smtp = Net::SMTP->new('mailhost.domain');
> print STDOUT $smtp->domain,"\n";
> $smtp->quit;
>
> just gives me :
>
> [error] Can't call method "domain" without a package
> or object reference at /perl/www-feedback.cgi line 100.\n
>
> Ruuning the same code as a stand alone perl script works OK.
>
> I have etc/hosts and resolve.conf in the chroot jail, as well as
> libresolv.so.2
>
> Any ideas, or do you require further information ?
The new() failed.
Always do your own error checking!
use Net::SMTP;
use strict;
use warnings;
my $smtp = Net::SMTP->new('mailhost')
or die "Net::SMTP new() failed: $@";
------------------------------
Date: 28 Apr 2005 01:15:01 GMT
From: Christopher Nehren <apeiron+usenet@coitusmentis.info>
Subject: Re: Net::SMTP in a chroot jail - can't initialise the connection
Message-Id: <slrnd70e8l.lsf.apeiron+usenet@prophecy.dyndns.org>
-----BEGIN xxx SIGNED MESSAGE-----
Hash: SHA1
On 2005-04-27, J. Gleixner scribbled these
curious markings:
> my $smtp = Net::SMTP->new('mailhost')
> or die "Net::SMTP new() failed: $@";
^^
I thought that $@ was only for eval()?
Best Regards,
Christopher Nehren
-----BEGIN xxx SIGNATURE-----
Version: GnuPG v1.4.1 (FreeBSD)
iD8DBQFCcDkVk/lo7zvzJioRAj53AJ9JcEfloirMHOn3PjHmvRNnlHAFrACgn69k
CrgLERFdcimaSXMpIn6LLww=
=mnlB
-----END PGP SIGNATURE-----
--
I abhor a system designed for the "user", if that word is a coded
pejorative meaning "stupid and unsophisticated". -- Ken Thompson
If you ask the wrong questions, you get answers like "42" and "God".
Unix is user friendly. However, it isn't idiot friendly.
------------------------------
Date: Wed, 27 Apr 2005 20:38:43 -0500
From: Wes Groleau <groleau+news@freeshell.org>
Subject: Re: one-time and one-line programs
Message-Id: <d4pep2$lbo$2@domitilla.aioe.org>
Anno Siegel wrote:
> Abigail <abigail@abigail.nl> wrote in comp.lang.perl.misc:
>
>> perl -pe '}{*_=*.}{' file # wc -l
>
>
> Nice. Why {*_=*.} and not {$_=$.}? Just obfuscation?
Speaking of obfuscation, what's "nice" about using
fifteen characters, over half punctuation, to replace five?
Or did I misunderstand the comment?
--
Wes Groleau
When all you have is a perl, everything looks like a string.
------------------------------
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.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
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 8022
***************************************