On 01/06/12 21:59, Simon Wistow wrote:
it's dog slow (fcvo 'dog')
I find my values of "dog" don't really apply (being Border Terriers), or
are unhelpful in these circumstances.
Try: "snail on mogodon". Less variability and very, very slow.
On Tue, May 22, 2012 at 02:48:05PM +0100, Roger Burton West said:
> On Tue, May 22, 2012 at 03:35:51PM +0200, Nic Gibson wrote:
> >search.cpan.org gives me far too many results for iCal. I need to parse
> >iCalendar (rfc 5545) files and then write them out as xCal (rfc 6321) files.
> >Does anyone
On 22/05/2012 22:35, Nic Gibson wrote:
search.cpan.org gives me far too many results for iCal.
Text::vFile is my weapon of choice for v-flavoured file formats, of which
iCalendar is a variant.
On Tue, May 22, 2012 at 03:35:51PM +0200, Nic Gibson wrote:
> search.cpan.org gives me far too many results for iCal. I need to parse
> iCalendar (rfc 5545) files and then write them out as xCal (rfc 6321) files.
> Does anyone have a particular recommendation for a module? Writing the XML
> isn
On 22 May 2012, at 18:10, David Cantrell wrote:
> On Tue, May 22, 2012 at 03:35:51PM +0200, Nic Gibson wrote:
>
>> search.cpan.org gives me far too many results for iCal. I need to parse
>> iCalendar (rfc 5545) files and then write them out as xCal (rfc 6321) files.
>> Does anyone have a parti
On Tue, May 22, 2012 at 03:35:51PM +0200, Nic Gibson wrote:
>search.cpan.org gives me far too many results for iCal. I need to parse
>iCalendar (rfc 5545) files and then write them out as xCal (rfc 6321) files.
>Does anyone have a particular recommendation for a module? Writing the XML
>isn't th
This appears to be my first message to london.pm in four years or so. Ho hum.
search.cpan.org gives me far too many results for iCal. I need to parse
iCalendar (rfc 5545) files and then write them out as xCal (rfc 6321) files.
Does anyone have a particular recommendation for a module? Writing th
On Jan 28, 2009, at 9:58 AM, Jonathan McKeown wrote:
On Wednesday 28 January 2009 15:24:43 Jonathan Stowe wrote:
2009/1/28 Jonathan McKeown :
On Wednesday 28 January 2009 14:30:20 Jonathan Kimmitt wrote:
However, what about this one:
for (my $i==0; $i<($tbl_width - 1); $i++) { }
Is an
On 29 Jan 2009, at 03:06, Avleen Vig wrote:
Peter Corlett wrote:
[...]
(My complaints about Python are in other annoying corners of the
language.)
Just curious, what else annoys you?
What I don't like:
The most obvious one is that it treats white space as significant and
uses it to ind
On Thu, Jan 29, 2009 at 12:52 PM, Andy Armstrong wrote:
> On 29 Jan 2009, at 12:41, James Laver wrote:
>>
>> Apparently not, I was just under the impression it did have it.
>>
>> I've programmed objc for all of 5 minutes before deciding I didn't
>> like it, not a language I'm even claiming compete
On 29 Jan 2009, at 12:41, James Laver wrote:
Apparently not, I was just under the impression it did have it.
I've programmed objc for all of 5 minutes before deciding I didn't
like it, not a language I'm even claiming competence in.
I've not used it for a few years - but I rather like it. If
On Thu, Jan 29, 2009 at 12:31 PM, Andy Armstrong wrote:
>
> But ObjC doesn't have operator overloading does it?
>
> From:
> http://borkwarellc.wordpress.com/2007/08/19/ \
>objective-c-is-stupid-but-i-still-like-it/
> or:
> http://lyxus.net/mel
Apparently not, I was just under the impression
On 29 Jan 2009, at 12:15, James Laver wrote:
As a result, classes like NSString override == and 'isEqual' to
actually do things like string comparisons. So you can use == on
string objects just fine :-)
This is where the overloading happens, and in a lot of other languages
as well (smalltalk fo
On Thu, Jan 29, 2009 at 12:05 PM, Andy Armstrong wrote:
>
> Is that true? I wasn't aware that ObjC did any operator overloading. The use
> of == to compare objects (pointers) is valid in C - that's not something
> that ObjC has added.
That's *before* overloading.
> On 29 Jan 2009, at 02:59, Avle
On 29 Jan 2009, at 02:59, Avleen Vig wrote:
On Wed, Jan 28, 2009 at 10:56 AM, Jonathan Kimmitt
wrote:
The next time I use == instead of eq to compare two strings, I
will know to expect it will always
evaluate to true. What other language does this (apart from C,
which would invariab
Jonathan Kimmitt wrote:
> However, what about this one:
>
> for (my $i==0; $i<($tbl_width - 1); $i++) { }
>
> Is anybody seriously arguing this could possibly do anything useful. Yet
> it is not trapped out as an error unless you add the obscure syntax:
I think you need a lollipop.
--
But
On Wed, Jan 28, 2009 at 2:02 PM, Peter Corlett wrote:
> $ python
> Python 2.5.2 (r252:60911, Aug 6 2008, 09:17:29)
> [GCC 4.3.1] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
'1' + '2'
> '12'
1 + 2
> 3
1 + '2'
> Traceback (most recent call last)
On Wed, Jan 28, 2009 at 10:56 AM, Jonathan Kimmitt
wrote:
>The next time I use == instead of eq to compare two strings, I
> will know to expect it will always
>evaluate to true. What other language does this (apart from C,
> which would invariably return false)
Objective C (which
On Wed, Jan 28, 2009 at 11:05 AM, Andy Armstrong wrote:
> On 28 Jan 2009, at 12:30, Jonathan Kimmitt wrote:
>>
>> Most people on this list seem to defend the perl design decision such
>> that
>>
>> if ($item == "xyzzy")
>>
>> should only emit a warning, because after all, a string can be converted
On Wed, Jan 28, 2009 at 08:47:56AM -0800, Ovid wrote:
> I'm just saying that while type theorists generally agree on the meaning of
> "static" and "dynamic" typing (and all languages contain elements of each),
> "strong" and "weak" typing don't have much meaning there. They only have
> meaning
2009/1/28 Ovid :
> - Original Message
>
>> From: Peter Corlett
>
>> > The problem with "strongly" and "weakly" typed is that different people
>> > define
>> them differently and they don't have much meaning in type systems. It's
>> static
>> typing and dynamic typing which is important
- Original Message
> From: Peter Corlett
> > The problem with "strongly" and "weakly" typed is that different people
> > define
> them differently and they don't have much meaning in type systems. It's
> static
> typing and dynamic typing which is important.
>
> Wikipedia says tha
On Wed, Jan 28, 2009 at 4:05 PM, Peter Corlett wrote:
> Wikipedia says that weakly- versus strongly-typed indicates how readily the
> language coerces between types. I'm not sure one can get much weaker than
> Perl on that front.
That's more or less what I based my message on.
Definitions taken
On 28 Jan 2009, at 15:27, Ovid wrote:
[...]
The problem with "strongly" and "weakly" typed is that different
people define them differently and they don't have much meaning in
type systems. It's static typing and dynamic typing which is
important.
Wikipedia says that weakly- versus strong
On Wed, Jan 28, 2009 at 02:46:30PM +, Nicholas Clark wrote:
> On Wed, Jan 28, 2009 at 02:21:45PM +, James Laver wrote:
>
> Fair enough. But it's also that with this Perl:
>
>$c = $a + $b;
>$d = $a . $b;
>
> then at compile time (heck at writing it time) I know what it is going to
- Original Message
> From: James Laver
> That's because python is strongly typed (though not statically typed
> -- it's a dynamic language).
No offense, but "strongly typed" doesn't have a huge amount of meaning, though
statically typed does. I highly recommend:
http://www.pphsg.o
On Wednesday 28 January 2009 15:24:43 Jonathan Stowe wrote:
> 2009/1/28 Jonathan McKeown :
> > On Wednesday 28 January 2009 14:30:20 Jonathan Kimmitt wrote:
> >> However, what about this one:
> >>
> >> for (my $i==0; $i<($tbl_width - 1); $i++) { }
> >>
> >> Is anybody seriously arguing this co
On Wed, Jan 28, 2009 at 02:21:45PM +, James Laver wrote:
> On Wed, Jan 28, 2009 at 2:02 PM, Peter Corlett wrote:
> > Python is dynamic and manages this just fine:
> >
> > $ python
> > Python 2.5.2 (r252:60911, Aug 6 2008, 09:17:29)
> > [GCC 4.3.1] on linux2
> > Type "help", "copyright", "cred
On Wed, Jan 28, 2009 at 10:56:41AM -, Jonathan Kimmitt wrote:
> Whoever said, the primary purpose of a compiler is to check for
> errors, and only if there are no errors, create the code, was most
> definitely not talking about Perl.
Or about half the XS on the CPAN. SGI's compilers are pick
On Wed, Jan 28, 2009 at 2:02 PM, Peter Corlett wrote:
> Python is dynamic and manages this just fine:
>
> $ python
> Python 2.5.2 (r252:60911, Aug 6 2008, 09:17:29)
> [GCC 4.3.1] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
'1' + '2'
> '12'
1 + 2
>
On 28 Jan 2009, at 14:02, Peter Corlett wrote:
On 28 Jan 2009, at 11:58, Nicholas Clark wrote:
[...]
Whereas in dynamic languages, a variable doesn't know its type at
run time, so you need two operators to ensure deterministic
behaviour and sanity.)
Python is dynamic and manages this just f
On 28 Jan 2009, at 12:26, Jonathan Stowe wrote:
2009/1/28 Mark Blackman :
On 28 Jan 2009, at 12:01, Paul Makepeace wrote:
Can you give an example where perl is doing something surprising
to you?
perl -le 'print "yes" if "a" == "b"'
Is the kind of case I suspect he's hit.
I guess that
On 28 Jan 2009, at 11:58, Nicholas Clark wrote:
[...]
Whereas in dynamic languages, a variable doesn't know its type at
run time, so you need two operators to ensure deterministic
behaviour and sanity.)
Python is dynamic and manages this just fine:
$ python
Python 2.5.2 (r252:60911, Aug 6
>> wrote:>> $ perl -le 'print "yes" if "a" ==
>> "2"'>> $ perl -le 'print "yes" if "a" == "a"'>> yes>> $ perl -le 'print
>> "yes" if "1" == "1"'>> yes>> $ perl -le 'print "yes" if "1" == "0"'>> $ perl
>> -le 'print "yes" if "1" == 1'>> yes>> $ Can you give an example where
>> perl is doin
On Wed, Jan 28, 2009 at 12:30:20PM -, Jonathan Kimmitt wrote:
> Most people on this list seem to defend the perl design decision such
> that
>
> if ($item == "xyzzy")
>
> should only emit a warning, because after all, a string can be converted
> to a number with no loss of meaning (!).
>
> H
On Wed, Jan 28, 2009 at 11:40 AM, Matt Jones wrote:
> On Wed, Jan 28, 2009 at 11:23 AM, Piers Cawley
> wrote:
>> Actually, I was surprised to find that there isn't a warning for that
>> with warnings turned on. Memory proving faulty.
>
> Am I missing something?
Nope, I was.
2009/1/28 Jonathan McKeown :
> On Wednesday 28 January 2009 14:30:20 Jonathan Kimmitt wrote:
>
>> However, what about this one:
>>
>> for (my $i==0; $i<($tbl_width - 1); $i++) { }
>>
>> Is anybody seriously arguing this could possibly do anything useful. Yet
>> it is not trapped out as an erro
On 28 Jan 2009, at 12:30, Jonathan Kimmitt wrote:
Most people on this list seem to defend the perl design decision such
that
if ($item == "xyzzy")
should only emit a warning, because after all, a string can be
converted
to a number with no loss of meaning (!).
However, what about this one:
On Wednesday 28 January 2009 14:30:20 Jonathan Kimmitt wrote:
> However, what about this one:
>
> for (my $i==0; $i<($tbl_width - 1); $i++) { }
>
> Is anybody seriously arguing this could possibly do anything useful. Yet
> it is not trapped out as an error unless you add the obscure syntax:
>
- Original Message
> From: Jonathan Kimmitt
> Most people on this list seem to defend the perl design decision such
> that
>
> if ($item == "xyzzy")
>
> should only emit a warning, because after all, a string can be converted
> to a number with no loss of meaning (!).
>
> However, wh
On Wed, Jan 28, 2009 at 12:30:20PM -, Jonathan Kimmitt wrote:
>
> However, what about this one:
>
> for (my $i==0; $i<($tbl_width - 1); $i++) { }
>
> Is anybody seriously arguing this could possibly do anything useful. Yet
> it
> is not trapped out as an error unless you add the obscure
On 28 Jan 2009, at 12:01, Paul Makepeace wrote:
Can you give an example where perl is doing something surprising to
you?
I assume the OP was surprised by:
$ perl -le 'print "a"=="b"'
1
--
Andy Armstrong, Hexten
2009/1/28 Jonathan Kimmitt :
> Most people on this list seem to defend the perl design decision such
> that
>
> if ($item == "xyzzy")
>
> should only emit a warning, because after all, a string can be converted
> to a number with no loss of meaning (!).
>
It's not so much a matter of defending the
Most people on this list seem to defend the perl design decision such
that
if ($item == "xyzzy")
should only emit a warning, because after all, a string can be converted
to a number with no loss of meaning (!).
However, what about this one:
for (my $i==0; $i<($tbl_width - 1); $i++) { }
Is
2009/1/28 Jonathan McKeown :
> On Wednesday 28 January 2009 14:01:22 Paul Makepeace wrote:
>>
>> Interesting that everyone's said to "use warnings" but no-one's
>> questioned what you're saying. Perl appears to me to DTRT:
>>
>> $ perl -le 'print "yes" if "a" == "2"'
>> $ perl -le 'print "yes" if "
2009/1/28 Mark Blackman :
>
> On 28 Jan 2009, at 12:01, Paul Makepeace wrote:
>
>> On Wed, Jan 28, 2009 at 11:31 AM, Dominic Thoreau
>> wrote:
>>>
>>> 2009/1/28 Jonathan Kimmitt :
The next time I use == instead of eq to compare two strings, I
will know to expect it will always
On Wed, Jan 28, 2009 at 12:15 PM, Mark Blackman wrote:
>
> On 28 Jan 2009, at 12:01, Paul Makepeace wrote:
>
>> On Wed, Jan 28, 2009 at 11:31 AM, Dominic Thoreau
>> wrote:
>>>
>>> 2009/1/28 Jonathan Kimmitt :
The next time I use == instead of eq to compare two strings, I
will
On Wednesday 28 January 2009 14:01:22 Paul Makepeace wrote:
>
> Interesting that everyone's said to "use warnings" but no-one's
> questioned what you're saying. Perl appears to me to DTRT:
>
> $ perl -le 'print "yes" if "a" == "2"'
> $ perl -le 'print "yes" if "a" == "a"'
> yes
> $ perl -le 'print
On 28 Jan 2009, at 12:01, Paul Makepeace wrote:
On Wed, Jan 28, 2009 at 11:31 AM, Dominic Thoreau
wrote:
2009/1/28 Jonathan Kimmitt :
The next time I use == instead of eq to compare two strings, I
will know to expect it will always
evaluate to true.
Interesting that everyone's
On 28 Jan 2009, at 10:56, Jonathan Kimmitt wrote:
It would be a trivial matter to return an error or warning if ==
is used for items which aren't numbers
Not at compile time - it's not generally knowable. At run time you /
do/ get a warning:
perl -w -le 'print q(a)==q(b)'
Argument "b
On Wed, Jan 28, 2009 at 11:31:37AM +, Dominic Thoreau wrote:
> Eg string concatenation in perl is with the . (dot) operator. In some
> other well used languages (Java, for example) the + operator is used,
> which is an overloading of the addition operator.
> I'm taking a series of courses in
On Wed, Jan 28, 2009 at 11:31 AM, Dominic Thoreau
wrote:
> 2009/1/28 Jonathan Kimmitt :
>>
>>The next time I use == instead of eq to compare two strings, I
>> will know to expect it will always
>>evaluate to true.
Interesting that everyone's said to "use warnings" but no-one's
que
On Wed, Jan 28, 2009 at 11:23 AM, Piers Cawley
wrote:
> Actually, I was surprised to find that there isn't a warning for that
> with warnings turned on. Memory proving faulty.
Am I missing something? If I put
if ( $foo == "really" )
Into a script with strict and warnings I get
Argument "really
2009/1/28 Jonathan Kimmitt :
>
>The next time I use == instead of eq to compare two strings, I
> will know to expect it will always
>evaluate to true. What other language does this (apart from C,
> which would invariably return false)
Unfortunately, this is perl being helpful. Beca
On Wed, Jan 28, 2009 at 11:23 AM, Piers Cawley
wrote:
> On Wed, Jan 28, 2009 at 10:56 AM, Jonathan Kimmitt
> wrote:
>>Whoever said, the primary purpose of a compiler is to check for
>> errors,
>>and only if there are no errors, create the code, was most
>> definitely not talking a
Jonathan Kimmitt wrote:
Whoever said, the primary purpose of a compiler is to check for
errors,
and only if there are no errors, create the code, was most
definitely not talking about Perl.
The next time I use == instead of eq to compare two strings, I
will know to expect it
On Wed, Jan 28, 2009 at 10:56 AM, Jonathan Kimmitt
wrote:
>The next time I use == instead of eq to compare two strings, I
> will know to expect it will always
>evaluate to true. What other language does this (apart from C,
> which would invariably return false)
PHP, which does it
On Wed, Jan 28, 2009 at 10:56:41AM -, Jonathan Kimmitt wrote:
> It would be a trivial matter to return an error or warning if ==
> is used for items which aren't numbers
>
> And this is in a language which is praised for its powerful
> string handling !
Um, it does throw a
- Original Message
> From: Jonathan Kimmitt
> The next time I use == instead of eq to compare two strings, I
> will know to expect it will always
> evaluate to true. What other language does this (apart from C,
> which would invariably return false)
> ld be a trivial matter to r
2009/1/28 Jonathan Kimmitt :
>Whoever said, the primary purpose of a compiler is to check for
> errors,
>and only if there are no errors, create the code, was most
> definitely not talking about Perl.
>
>The next time I use == instead of eq to compare two strings, I
> will k
On Wed, Jan 28, 2009 at 10:56 AM, Jonathan Kimmitt
wrote:
>Whoever said, the primary purpose of a compiler is to check for
> errors,
>and only if there are no errors, create the code, was most
> definitely not talking about Perl.
>
>The next time I use == instead of eq to c
On 28 Jan 2009, at 10:56, Jonathan Kimmitt wrote:
It would be a trivial matter to return an error or warning if ==
is used for items which aren't numbers
You mean like the one emitted if you happen to have "use warnings" at
the top of your code?
Now obviously perl should emit an error if
On 28 Jan 2009, at 10:56, Jonathan Kimmitt wrote:
Whoever said, the primary purpose of a compiler is to check for
errors,
and only if there are no errors, create the code, was most
definitely not talking about Perl.
The next time I use == instead of eq to compar
Whoever said, the primary purpose of a compiler is to check for
errors,
and only if there are no errors, create the code, was most
definitely not talking about Perl.
The next time I use == instead of eq to compare two strings, I
will know to expect it will always
On Mon, Nov 17, 2008 at 02:25:16PM +, Nicholas Clark wrote:
> On Thu, Nov 13, 2008 at 04:03:53PM +, Lon Brocard wrote:
> > How is 5.8.9 RC1 working out for everyone?
> Works on my machine. Funny that. :-)
I was going to try it on some code of mine that can make 5.8.8 segfault.
Unfortunatel
On Thu, Nov 13, 2008 at 04:03:53PM +, Lon Brocard wrote:
> 2008/11/11 Nicholas Clark <[EMAIL PROTECTED]>:
>
> > ftp://ftp.cpan.org/pub/CPAN/authors/id/N/NW/NWCLARK/perl-5.8.9-RC1.tar.bz2
> > no-one has tested it on *your* work code. And if you don't, and there are
> > regressions in RC1 that h
On 14 Nov 2008, at 19:01, Steve Purkis wrote:
On Nov 13, 2008, at 16:03, Léon Brocard wrote:
2008/11/11 Nicholas Clark <[EMAIL PROTECTED]>:
ftp://ftp.cpan.org/pub/CPAN/authors/id/N/NW/NWCLARK/perl-5.8.9-RC1.tar.bz2
no-one has tested it on *your* work code. And if you don't, and
there are
On Nov 13, 2008, at 16:03, Léon Brocard wrote:
2008/11/11 Nicholas Clark <[EMAIL PROTECTED]>:
ftp://ftp.cpan.org/pub/CPAN/authors/id/N/NW/NWCLARK/perl-5.8.9-
RC1.tar.bz2
no-one has tested it on *your* work code. And if you don't, and
there are
regressions in RC1 that hurt your code, but you
On Thu, 13 Nov 2008, Léon Brocard wrote:
2008/11/11 Nicholas Clark <[EMAIL PROTECTED]>:
ftp://ftp.cpan.org/pub/CPAN/authors/id/N/NW/NWCLARK/perl-5.8.9-RC1.tar.bz2
no-one has tested it on *your* work code. And if you don't, and there are
regressions in RC1 that hurt your code, but you don't fin
We've tested RT, Jifty, SVK and Prophet on it on linux and osx. Generally
things look happy
Léon Brocard <[EMAIL PROTECTED]> wrote:
>2008/11/11 Nicholas Clark <[EMAIL PROTECTED]>:
>
>> ftp://ftp.cpan.org/pub/CPAN/authors/id/N/NW/NWCLARK/perl-5.8.9-RC1.tar.bz2
>> no-one has tested it on *your* wo
2008/11/11 Nicholas Clark <[EMAIL PROTECTED]>:
> ftp://ftp.cpan.org/pub/CPAN/authors/id/N/NW/NWCLARK/perl-5.8.9-RC1.tar.bz2
> no-one has tested it on *your* work code. And if you don't, and there are
> regressions in RC1 that hurt your code, but you don't find out until after
> 5.8.9 is released,
Sorry to digress from important topics such as beer, buffy and pie, but
Perl 5.8.9 Release Candidate 1 has been uploaded to CPAN. This is a
maintenance release for perl 5.8.x, providing bug fixes and integrating
module updates from CPAN. Download the source from
ftp://ftp.cpan.org/pub/CPAN
On Fri, 8 Aug 2003, Jonathan Peterson wrote:
> I came across this crowd:
>
> http://www.indigostar.com/
I haven't used the software, but I met Indy (who is indigostar) at this
year's YAPC::NA. He was going around the pool and giving people beer
which Was A Nice Thing To Do.
This is my extent of
I have the all to common "Can we put our website on a CD?" request from
management.
I was about to write a politely informative document outlining the
differences between a CD and a website, but decided that was a bit
defeatist. I came across this crowd:
http://www.indigostar.com/
Who seem to
When starting a new thread, please could people remember to cut&paste the
e-mail address into a new message, rather than replying to an existing
message and just scrubbing the subject and body. Evidence remains:
References: <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> <[EMAIL PROTECTED]>
and decent m
Hi,
for lack of a better idea about a place to post this terribly Perlish question,
I am bothering you with it here. Feel free to flame me.
I have this CSS::SAC module which uses Text::Balanced a fair lot. It needs to
parse things like this:
body {
/*
strange } in that URL there...
Apparently this is my job, since I start with a new company in February.
We've recently merged with our biggest affiliate who will probably
overturn my hard work involved in getting the company to use Template
Toolkit via a funky mod-perl MVC architecture which I've developed.
Grrr. They are looki
Scottow Adrian - adscot wrote:
> This suprised me today. What happens with return and map and
> anonymous subroutines. It seems to me that the return is not
> treated as a return from the snippet of code in the map but
> rather a return for the anonymous subroutine.
Well, yeah.
Returns fr
Hey look! Another Perl Thread!
This suprised me today. What happens with return and map and anonymous
subroutines. It seems to me that the return is not treated as a return from
the snippet of code in the map but rather a return for the anonymous
subroutine.
This example is rather trivial...
Paul Makepeace wrote:
> On Wed, May 29, 2002 at 06:34:07PM +0100, nemesis wrote:
>
>>Hi All,
>>
>>I have a script that gets some pages and it needs to remember the cookies
>>they so generously provide. I have dones this using the cookie jar
>>functionality of the LWP::UserAgent module:
>>
>>my
On Wed, May 29, 2002 at 06:34:07PM +0100, nemesis wrote:
> Hi All,
>
> I have a script that gets some pages and it needs to remember the cookies
> they so generously provide. I have dones this using the cookie jar
> functionality of the LWP::UserAgent module:
>
> my $ua = LWP::UserAgent->new(
Hi All,
I have a script that gets some pages and it needs to remember the cookies they so
generously
provide. I have dones this using the cookie jar functionality of the LWP::UserAgent
module:
my $ua = LWP::UserAgent->new();
$ua->cookie_jar(HTTP::Cookies->new(file => "/path/to/lwpcookies.txt
On Wed, 2002-01-16 at 07:03, Newton, Philip wrote:
> AFAIK, Apache manages to pass content along to the client as soon as it
> receives it from the CGI program, even on Win32.
Nope, at least not yet. It's been going to be fixed in the next release
for quite a while.
2.0 though. Yep, it'll b
Sam Vilain wrote:
> On Wed, 16 Jan 2002 09:20:49 +0100
> "Newton, Philip" <[EMAIL PROTECTED]> wrote:
>
> > FYI, the Xitami web server (at least on Win32 systems)
> > doesn't output any of the CGI's output to the client
> > until the CGI is done, so perhaps it implements CGI
> > with STDOUT direc
On Wed, 16 Jan 2002 09:20:49 +0100
"Newton, Philip" <[EMAIL PROTECTED]> wrote:
> FYI, the Xitami web server (at least on Win32 systems) doesn't output any of
> the CGI's output to the client until the CGI is done, so perhaps it
> implements CGI with STDOUT directed to a file, which it then reads
Nicholas Clark wrote:
> Does a CGI always run with a socket as STDOUT?
> (in that running with a CGI-faked ENV as part of a pipe in a
> cron job is going to look awfuly like being run from a web
> server)
>
> Or will there be servers that run the CGI with the output to
> a pipe and in turn pump
On Tue, Jan 15, 2002 at 04:15:29PM +, [EMAIL PROTECTED] wrote:
> I'd be very surprised if you have a terminal in a cron job (which was
> one possibility from the original requirements above). You can
> probably also use POSIX::isatty() from perl but I haven't checked
> it in detail, or the -t
On Tue, Jan 15, 2002 at 05:27:45PM +, Dominic Mitchell wrote:
> nemesis <[EMAIL PROTECTED]> writes:
> > Thanks to everyone who helped. I will dump all the $ENV variable see
> > what I can see in the different cases.
>
> Alternatively, have a look at some of the test cgi scripts that come
> w
nemesis <[EMAIL PROTECTED]> writes:
> Thanks to everyone who helped. I will dump all the $ENV variable see
> what I can see in the different cases.
Alternatively, have a look at some of the test cgi scripts that come
with apache. I was far too lazy to actually write a CGI to find that
one out.
On Tue, Jan 15, 2002 at 04:06:40PM +, David Cantrell wrote:
> In C, you want isatty(3). In perl, try stat()ing STDIN.
Or just use:
if (-t) { ...}
Pretty unreliable though - what if you used it in a pipe? I think the
environment is a better way to go. It's actually pretty useful that
you
Dominic Mitchell wrote:
> nemesis <[EMAIL PROTECTED]> writes:
>
>
>>Anyone know of a way of telling whether a perl script was called as a
>>CGI (via the apache webserver) or directly (as in as a cron script or
>>command line)?
>>
>
> if (exists $ENV{SERVER_NAME}) {
> print "I'm a cgi (
On Tue, Jan 15, 2002 at 03:26:42PM +, Struan Donald wrote:
> * at 15/01 15:21 + nemesis said:
> > Anyone know of a way of telling whether a perl script was called as a
> > CGI (via the apache webserver) or directly (as in as a cron script or
> > command line)?
> will be a whole load of e
nemesis <[EMAIL PROTECTED]> writes:
> Anyone know of a way of telling whether a perl script was called as a
> CGI (via the apache webserver) or directly (as in as a cron script or
> command line)?
if (exists $ENV{SERVER_NAME}) {
print "I'm a cgi (probably)\n";
} else {
print "I d
use getpwnam to find out who the user is.
http://www.atlantageek.com
Get inside Atlanta's Tech scene
On Tue, 15 Jan 2002, nemesis wrote:
>
> Anyone know of a way of telling whether a perl script was called as a
> CGI (via the apache webserver) or directly (as in as a cron script or
> command l
* at 15/01 15:21 + nemesis said:
>
> Anyone know of a way of telling whether a perl script was called as a
> CGI (via the apache webserver) or directly (as in as a cron script or
> command line)?
will be a whole load of exciting CGI type things in %ENV if it's a cgi
call so you could test
On Tue, 15 Jan 2002, nemesis wrote:
> Anyone know of a way of telling whether a perl script was called as a
> CGI (via the apache webserver) or directly (as in as a cron script or
> command line)?
Take a look at %ENV. I'm guessing that $ENV{'SERVER_NAME'} et al won't be
set when running as a cr
Anyone know of a way of telling whether a perl script was called as a
CGI (via the apache webserver) or directly (as in as a cron script or
command line)?
Will.
--
*claw claw* *fang*
*shred* *rip* *ad hominem* *slash*
(more attacks will require consultancy fees.)
-Nix.
97 matches
Mail list logo