[30388] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 1631 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Jun 11 09:09:46 2008

Date: Wed, 11 Jun 2008 06:09:09 -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           Wed, 11 Jun 2008     Volume: 11 Number: 1631

Today's topics:
    Re: ConTEXT editor and Perl <sean.prawn@gmail.com>
        cool jokes, and good readings <CoolRosy@gmail.com>
    Re: FAQ 5.13 How can I output my numbers with commas ad <dalessio@motorola.NOSPAM.com>
    Re: FAQ 5.13 How can I output my numbers with commas ad <brian.d.foy@gmail.com>
    Re: FAQ 7.26 How can I find out my current package? <mjcarman@mchsi.com>
    Re: FAQ 7.26 How can I find out my current package? <uri@stemsystems.com>
    Re: Moving from delimited to XML <cartercc@gmail.com>
    Re: Moving from delimited to XML sln@netherlands.co
    Re: Moving from delimited to XML <tadmc@seesig.invalid>
        new CPAN modules on Wed Jun 11 2008 (Randal Schwartz)
    Re: output of a command in an variable <whynot@pozharski.name>
    Re: Perl DBI Module: SQL query where there is space in  <robsku@NO-SPAM-REMOVE-THIS.fiveam.org>
    Re: Perl on embedded device <jluis@agujeronegro.escomposlinux.org>
        please help me for my script <john.swilting@wanadoo.fr>
    Re: please help me for my script <danrumney@warpmail.net>
    Re: please help me for my script <benkasminbullock@gmail.com>
    Re: Time and again <bill@ts1000.us>
    Re: Time and again <tadmc@seesig.invalid>
    Re: Tk with Thread <zentara@highstream.net>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Wed, 11 Jun 2008 06:20:28 +0100
From: prawn <sean.prawn@gmail.com>
Subject: Re: ConTEXT editor and Perl
Message-Id: <st34i5-qt5.ln1@prawn.mine.nu>

On Tue, 10 Jun 2008 14:56:38 -0700, Bill H wrote:

> Has anyone used ConTEXT (http://www.contexteditor.org/) when working on
> perl code? I am currently using it with my actionscript code and am
> about 95% happy* and am considering using it for the perl code too.
> Currently I use good old edit.com for large programs or notepad to make
> a few minor changes.
> 
> Bill H
> 
> * 5% unhappy because it has a few bugs on auto-indenting and
> occasionally the focus gets stuck in the project panel and I have to
> close and restart it.

Until a couple of years a go it was my editor of choice on windows 
boxen.  I only stopped using it because I'm Linux based these days.

My only minor gripe with it was that the syntax highlighting would get 
its knickers in a twist with some PHP/HTML code though the Perl parsing 
seemed to be fine.

-- 
p BotM#1 LotR#9
http://www.last.fm/user/prawnuk


------------------------------

Date: Wed, 11 Jun 2008 01:23:47 -0700 (PDT)
From: Preeti <CoolRosy@gmail.com>
Subject: cool jokes, and good readings
Message-Id: <2b792dee-b258-41ed-a6ee-fb1b5a990d41@t12g2000prg.googlegroups.com>

visit

http://slipofmind.blogspot.com

Thanks

Preeti


------------------------------

Date: Tue, 10 Jun 2008 10:15:41 -0500
From: "Mario D'Alessio" <dalessio@motorola.NOSPAM.com>
Subject: Re: FAQ 5.13 How can I output my numbers with commas added?
Message-Id: <g2m6bq$60s$1@newshost.mot.com>

Rather than using a complex RE, I reverse the
string and then just add a comma after each set
of 3 numbers:

 $s = reverse $s;
 $s =~ s/(\d{3})/\1,/g;
 $s =~ s/,$//;
 reverse $s;

Besides the fact that my code ignores the plus
and minus signs and the decimal point, is there any
other advantage to using the REs below? I'm guessing
that my two uses of "reverse" and the simple RE would
be more efficient than the complex REs below.

Just wondering...

Mario

"PerlFAQ Server" <brian@stonehenge.com> wrote in message 
news:5il1i5-gev.ln1@blue.stonehenge.com...
> This is an excerpt from the latest version perlfaq5.pod, which
> comes with the standard Perl distribution. These postings aim to
> reduce the number of repeated questions as well as allow the community
> to review and update the answers. The latest version of the complete
> perlfaq is at http://faq.perl.org .
>
> --------------------------------------------------------------------
>
> 5.13: How can I output my numbers with commas added?
>
>
>    (contributed by brian d foy and Benjamin Goldberg)
>
>    You can use Number::Format to separate places in a number. It handles
>    locale information for those of you who want to insert full stops
>    instead (or anything else that they want to use, really).
>
>    This subroutine will add commas to your number:
>
>            sub commify {
>                    local $_  = shift;
>                    1 while s/^([-+]?\d+)(\d{3})/$1,$2/;
>                    return $_;
>                    }
>
>    This regex from Benjamin Goldberg will add commas to numbers:
>
>            s/(^[-+]?\d+?(?=(?>(?:\d{3})+)(?!\d))|\G\d{3}(?=\d))/$1,/g;
>
>    It is easier to see with comments:
>
>            s/(
>                    ^[-+]?             # beginning of number.
>                    \d+?               # first digits before first comma
>                    (?=                # followed by, (but not included in 
> the match) :
>                            (?>(?:\d{3})+) # some positive multiple of 
> three digits.
>                            (?!\d)         # an *exact* multiple, not x * 3 
> + 1 or whatever.
>                    )
>                    |                  # or:
>                    \G\d{3}            # after the last group, get three 
> digits
>                    (?=\d)             # but they have to have more digits 
> after them.
>            )/$1,/xg;
>
>
>
> --------------------------------------------------------------------
>
> The perlfaq-workers, a group of volunteers, maintain the perlfaq. They
> are not necessarily experts in every domain where Perl might show up,
> so please include as much information as possible and relevant in any
> corrections. The perlfaq-workers also don't have access to every
> operating system or platform, so please include relevant details for
> corrections to examples that do not work on particular platforms.
> Working code is greatly appreciated.
>
> If you'd like to help maintain the perlfaq, see the details in
> perlfaq.pod. 




------------------------------

Date: Wed, 11 Jun 2008 07:49:24 -0500
From: brian d  foy <brian.d.foy@gmail.com>
Subject: Re: FAQ 5.13 How can I output my numbers with commas added?
Message-Id: <110620080749240173%brian.d.foy@gmail.com>

In article <g2m6bq$60s$1@newshost.mot.com>, Mario D'Alessio
<dalessio@motorola.NOSPAM.com> wrote:

> Rather than using a complex RE, I reverse the
> string and then just add a comma after each set
> of 3 numbers:

Try it with 1234567.1234567 :)


------------------------------

Date: Wed, 11 Jun 2008 01:21:28 GMT
From: Michael Carman <mjcarman@mchsi.com>
Subject: Re: FAQ 7.26 How can I find out my current package?
Message-Id: <sMF3k.203198$yE1.191856@attbi_s21>

> 7.26: How can I find out my current package?

The answer doesn't mention caller() but probably should.

     If you're a subroutine and want to know the package you were called
     from use the C<caller> function:

         my $package = caller();

-mjc


------------------------------

Date: Wed, 11 Jun 2008 03:32:32 GMT
From: Uri Guttman <uri@stemsystems.com>
Subject: Re: FAQ 7.26 How can I find out my current package?
Message-Id: <x7prqok5ny.fsf@mail.sysarch.com>

>>>>> "MC" == Michael Carman <mjcarman@mchsi.com> writes:

  >> 7.26: How can I find out my current package?
  MC> The answer doesn't mention caller() but probably should.

  MC>      If you're a subroutine and want to know the package you were called
  MC>      from use the C<caller> function:

  MC>          my $package = caller();

the question is current package, not the called from
package. __PACKAGE__ is all that is needed.

uri

-- 
Uri Guttman  ------  uri@stemsystems.com  --------  http://www.sysarch.com --
-----  Perl Code Review , Architecture, Development, Training, Support ------
--------- Free Perl Training --- http://perlhunter.com/college.html ---------
---------  Gourmet Hot Cocoa Mix  ----  http://bestfriendscocoa.com ---------


------------------------------

Date: Tue, 10 Jun 2008 15:26:41 -0700 (PDT)
From: cartercc <cartercc@gmail.com>
Subject: Re: Moving from delimited to XML
Message-Id: <582a4317-bc30-4a9a-a906-4c9648d11641@y38g2000hsy.googlegroups.com>

On Jun 9, 7:53 pm, Bill H <b...@ts1000.us> wrote:
> In most of my programs I use small tab or | delimited text to store
> data (mostly because the data came from excel files to begin with).
> These "databases" are usually only 10 - 15 fields per record and about
> 100 or so records, so the overhead in using a real database is not
> needed.
>
> Recently I have started using XML in other areas and realize that this
> format would be more easily maintained then the text files. So the
> question of the day, can someone point me to some simple XML
> implementation in perl that wont take days to learn and includes some
> commentary on how it works that is geared more to the layman?

The difference between a CSV format and an XML format is that the
latter does not have to be normalized. As you point out, in XML a
person may have zero or more names, zero or more streets, zero or more
emails, zero or more phones, etc. You can't do this with a CSV format
because you need to have a 'column' for every value. Same thing is
true for an RDBMS.

Both formats are good, but for different things. It strikes me that,
if you are interested in XML, you should spend time learning XSLT and
Java before you start to use Perl to manipulate the XML. You can
certainly do your zip code stuff with XSLT easier than with Perl.
(Java's a different story, but Java has XML classes and parsers built
in.)

In my job, I use a lot of data files, some of them very big, and write
a lot of scripts manipulating these files. We extract data from our
databases both in a CSV format and as XML.* I use both CSV and XML.
These formats are not interchangeable, like a hammer and a screwdriver
are not interchangeable. Which tool you use depends on your task, if
you have nails you use a hammer and if you have screws you use a
screwdriver.

You might also want to check out Exist, a XML database.
http://exist.sourceforge.net/
This uses XQuery and XPath. You can see how it handles free form data
that would otherwise be extremely difficult to store in an RDB.

IMO, Perl isn't really suited for XML. This is just my opinion, but
it's based on several years of practical experience of dealing with
XML files.

CC

*Our big database uses an IBM product called UniData, which is a non-
first normal form relational database technology, and MOST of our
fields are multi-valued which explains why I find XML so useful. For
example, a student can have from zero to over a hundred classes to his
credit, which are all stored in one 'field'. So ... if I extract the
data as CSV and import them into Excel, I get a very ragged right
margin and very scrambled columns.


------------------------------

Date: Tue, 10 Jun 2008 16:30:29 -0700
From: sln@netherlands.co
Subject: Re: Moving from delimited to XML
Message-Id: <8g3u4453269u8a2pfrveb839c7in1l9p8v@4ax.com>

On Tue, 10 Jun 2008 15:26:41 -0700 (PDT), cartercc <cartercc@gmail.com> wrote:

>On Jun 9, 7:53 pm, Bill H <b...@ts1000.us> wrote:
>> In most of my programs I use small tab or | delimited text to store
>> data (mostly because the data came from excel files to begin with).
>> These "databases" are usually only 10 - 15 fields per record and about
>> 100 or so records, so the overhead in using a real database is not
>> needed.
>>
>> Recently I have started using XML in other areas and realize that this
>> format would be more easily maintained then the text files. So the
>> question of the day, can someone point me to some simple XML
>> implementation in perl that wont take days to learn and includes some
>> commentary on how it works that is geared more to the layman?
>
>The difference between a CSV format and an XML format is that the
>latter does not have to be normalized. As you point out, in XML a
>person may have zero or more names, zero or more streets, zero or more
>emails, zero or more phones, etc. You can't do this with a CSV format
>because you need to have a 'column' for every value. Same thing is
>true for an RDBMS.
>
>Both formats are good, but for different things. It strikes me that,
>if you are interested in XML, you should spend time learning XSLT and
>Java before you start to use Perl to manipulate the XML. You can
>certainly do your zip code stuff with XSLT easier than with Perl.
>(Java's a different story, but Java has XML classes and parsers built
>in.)
>
>In my job, I use a lot of data files, some of them very big, and write
>a lot of scripts manipulating these files. We extract data from our
>databases both in a CSV format and as XML.* I use both CSV and XML.
>These formats are not interchangeable, like a hammer and a screwdriver
>are not interchangeable. Which tool you use depends on your task, if
>you have nails you use a hammer and if you have screws you use a
>screwdriver.
>
>You might also want to check out Exist, a XML database.
>http://exist.sourceforge.net/
>This uses XQuery and XPath. You can see how it handles free form data
>that would otherwise be extremely difficult to store in an RDB.
>
>IMO, Perl isn't really suited for XML. This is just my opinion, but
>it's based on several years of practical experience of dealing with
>XML files.
>

>CC
>
>*Our big database uses an IBM product called UniData, which is a non-
>first normal form relational database technology, and MOST of our
>fields are multi-valued which explains why I find XML so useful. For
>example, a student can have from zero to over a hundred classes to his
>credit, which are all stored in one 'field'. So ... if I extract the
>data as CSV and import them into Excel, I get a very ragged right
>margin and very scrambled columns.

WTF are you talking about?
You should get "normalized"...

sln



------------------------------

Date: Tue, 10 Jun 2008 22:32:04 -0500
From: Tad J McClellan <tadmc@seesig.invalid>
Subject: Re: Moving from delimited to XML
Message-Id: <slrng4uhpk.4qi.tadmc@tadmc30.sbcglobal.net>

sln@netherlands.co <sln@netherlands.co> wrote:
> On Tue, 10 Jun 2008 15:26:41 -0700 (PDT), cartercc <cartercc@gmail.com> wrote:

>>*Our big database uses an IBM product called UniData, which is a non-
>>first normal form relational database technology,


> WTF are you talking about?


   http://en.wikipedia.org/wiki/Database_normalization


> You should get "normalized"...


Pardon me, but your ignorance is showing.

Again.


-- 
Tad McClellan
email: perl -le "print scalar reverse qq/moc.noitatibaher\100cmdat/"


------------------------------

Date: Wed, 11 Jun 2008 04:42:19 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Wed Jun 11 2008
Message-Id: <K2A7qJ.1toA@zorch.sf-bay.org>

The following modules have recently been added to or updated in the
Comprehensive Perl Archive Network (CPAN).  You can install them using the
instructions in the 'perlmodinstall' page included with your Perl
distribution.

Acme-Colour-1.06
http://search.cpan.org/~lbrocard/Acme-Colour-1.06/
additive and subtractive human-readable colours 
----
Apache2-AuthEnv-1.1
http://search.cpan.org/~arif/Apache2-AuthEnv-1.1/
Perl Authentication and Authorisation via Environment Variables. 
----
App-Todo-0.94
http://search.cpan.org/~tsibley/App-Todo-0.94/
Provides todo.pl, a command-line interface to Hiveminder 
----
App-Todo-0.95
http://search.cpan.org/~tsibley/App-Todo-0.95/
Provides todo.pl, a command-line interface to Hiveminder 
----
CPAN-Reporter-1.15_55
http://search.cpan.org/~dagolden/CPAN-Reporter-1.15_55/
Adds CPAN Testers reporting to CPAN.pm 
----
DateTime-Format-Oracle-0.05
http://search.cpan.org/~kolibrie/DateTime-Format-Oracle-0.05/
Parse and format Oracle dates and timestamps 
----
Dir-Project-3.012
http://search.cpan.org/~wsnyder/Dir-Project-3.012/
Project Environment determination 
----
File-Assets-0.060_2
http://search.cpan.org/~rkrimen/File-Assets-0.060_2/
Manage .css and .js assets in a web application 
----
File-PathInfo-Ext-1.22
http://search.cpan.org/~leocharre/File-PathInfo-Ext-1.22/
metadata files, renaming, some other things on top of PathInfo 
----
Games-Sudoku-CPSearch-0.14
http://search.cpan.org/~martyloo/Games-Sudoku-CPSearch-0.14/
Solve Sudoku problems quickly. 
----
Gtk2-Phat-0.07
http://search.cpan.org/~flora/Gtk2-Phat-0.07/
Perl interface to the Phat widget collection 
----
HTTP-Server-Simple-0.34
http://search.cpan.org/~jesse/HTTP-Server-Simple-0.34/
Lightweight HTTP server 
----
Math-Random-MT-Auto-6.13
http://search.cpan.org/~jdhedden/Math-Random-MT-Auto-6.13/
Auto-seeded Mersenne Twister PRNGs 
----
MooseX-Struct-0.06
http://search.cpan.org/~jsoverson/MooseX-Struct-0.06/
----
Mouse-0.01
http://search.cpan.org/~sartak/Mouse-0.01/
Moose minus the antlers 
----
Net-ManageSieve-0.05
http://search.cpan.org/~ska/Net-ManageSieve-0.05/
ManageSieve Protocol Client 
----
Net-SMS-2Way-0.04
http://search.cpan.org/~lengel/Net-SMS-2Way-0.04/
BulkSMS API 
----
POE-Component-SSLify-0.12
http://search.cpan.org/~apocal/POE-Component-SSLify-0.12/
Makes using SSL in the world of POE easy! 
----
POE-Component-SSLify-0.13
http://search.cpan.org/~apocal/POE-Component-SSLify-0.13/
Makes using SSL in the world of POE easy! 
----
POE-Component-SimpleDBI-1.22
http://search.cpan.org/~apocal/POE-Component-SimpleDBI-1.22/
Asynchronous non-blocking DBI calls in POE made simple 
----
POE-Component-SpreadClient-0.06
http://search.cpan.org/~apocal/POE-Component-SpreadClient-0.06/
handle Spread communications in POE 
----
POE-Filter-Zlib-2.00
http://search.cpan.org/~bingos/POE-Filter-Zlib-2.00/
A POE filter wrapped around Compress::Zlib 
----
String-Prettify-1.02
http://search.cpan.org/~leocharre/String-Prettify-1.02/
subs to cleanup a filename and or garble for human eyes 
----
Template-Plugin-Cycle-1.05
http://search.cpan.org/~adamk/Template-Plugin-Cycle-1.05/
Cyclically insert into a Template from a sequence of values 
----
Test-File-1.25
http://search.cpan.org/~bdfoy/Test-File-1.25/
test file attributes 
----
Thread-Cancel-1.08
http://search.cpan.org/~jdhedden/Thread-Cancel-1.08/
Cancel (i.e., kill) threads 
----
Thread-Suspend-1.18
http://search.cpan.org/~jdhedden/Thread-Suspend-1.18/
Suspend and resume operations for threads 
----
WWW-YouTube-2008.0610
http://search.cpan.org/~ermeyers/WWW-YouTube-2008.0610/
YouTube Development Interface (YTDI) 
----
clickTk-4.013
http://search.cpan.org/~mmarco/clickTk-4.013/
----
eGuideDog-Dict-Mandarin-0.44
http://search.cpan.org/~hgneng/eGuideDog-Dict-Mandarin-0.44/
an informal Pinyin dictionary. 
----
iTunes-Sid-0.01_01
http://search.cpan.org/~billh/iTunes-Sid-0.01_01/
----
mobirc-0.99_05
http://search.cpan.org/~tokuhirom/mobirc-0.99_05/
modern IRC to HTTP gateway 
----
mobirc-0.99_06
http://search.cpan.org/~tokuhirom/mobirc-0.99_06/
modern IRC to HTTP gateway 


If you're an author of one of these modules, please submit a detailed
announcement to comp.lang.perl.announce, and we'll pass it along.

This message was generated by a Perl program described in my Linux
Magazine column, which can be found on-line (along with more than
200 other freely available past column articles) at
  http://www.stonehenge.com/merlyn/LinuxMag/col82.html

print "Just another Perl hacker," # the original

--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion


------------------------------

Date: Tue, 10 Jun 2008 21:41:01 +0300
From: Eric Pozharski <whynot@pozharski.name>
Subject: Re: output of a command in an variable
Message-Id: <teu2i5xhpd.ln2@carpet.zombinet>

Natxo Asenjo <natxete@asenjo.nl.invalid> wrote:
*SKIP*
> my $arcconf = `arcconf\.exe getconfig 1 ad`;

> open(OUTPUT, $arcconf) or die "Can't run $arcconf: $!\n" ;
> while (<OUTPUT>) {
>    print $_ ."\n" ;
> }

*SKIP*
> Why am I getting the 'Unsuccessful ..." warnings? How can I get rid of
> them?

Because you're trying to open B<output> of C<arcconf.exe getconfig 1 ad>
for...  output.  I suppose, that yours blah-blah toy blah-blah operating
blah-blah system is unhappy with some characters in filename (perl is
using value of I<$arcconf> as a filename), filename length, whatever.

Reread L<perlopentut>.

#/usr/bin/perl
use strict;
use warnings;

open my $output, '-|', 'arcconf.exe getconfig 1 ad' or
  die "can't run arcconf: $?";
while(my $line = <$output>) {
	print $line; };
close $output or
  die "can't get rid of arcconf: $?";

__END__

I suppose you're going to tinker with output, right?  Then remember,
I<$line> still contains trailing C<"\n">.

-- 
Torvalds' goal for Linux is very simple: World Domination


------------------------------

Date: Wed, 11 Jun 2008 13:30:53 +0300
From: Sir Robin <robsku@NO-SPAM-REMOVE-THIS.fiveam.org>
Subject: Re: Perl DBI Module: SQL query where there is space in field name
Message-Id: <dq8v44hms8ni1dulq76odm3b2jau8d31dn@4ax.com>

On Fri, 16 May 2008 20:07:20 -0700, Andrew DeFaria <Andrew@DeFaria.com> wrote:

>Sir Robin wrote:
>> On Mon, 12 May 2008 07:35:27 -0700, Andrew DeFaria 
>> <Andrew@DeFaria.com> wrote:
>>> And then there are assholes who will waste tons of bandwidth arguing 
>>> that they are wasting bandwidth! Brilliant argument there bud.
>> I'm glad that you agree.
>Hmmm... Sounds like somebody cannot detect sarcasm.

Indeed it does.

>>> Here's a wonderful reason - because it bothers you.
>> Say, you can't really read, can you?
>Sure I can read. Hey, I can even disagree with you!

No - you cant. Read, that is. On blindly disagreeing you do master the talent.

>> No, *I* can ignore it quite well but it would indeed be a wonderful 
>> reason. My reason is that:
>>
>> 1. It bothers *others*.
>> 2. No benefit whatsoever.
>>
>> So GTFY.
>Why don't you let the others argue themselves if it really doesn't 
>bother you?

That your kind will propably never be able to understand.

>>>> As it does not give any value to the content of your message, makes 
>>>> your messages multiple times larger and for some readers it shows as 
>>>> a huge amount of total crap and thus causes negativity - as I can 
>>>> see only negative things resulting from HTML posting I can only come 
>>>> to conclusion that after this has been specifically pointed to you 
>>>> clearly you can be classified as a troll.
>>> I see - the "do it my way or you're a troll" opinion...
>> Yes, that is indeed my opinion on this case of the meaning for "my way".
>Great! Then it must burn you so that you opinion matters not to me.

You seem to have this obsession like fantasy of causing such reactions... No
luck here, but I do wonder what made you like that...

>>> And, of course, you're so damn social that you feel the need to tell 
>>> people how to do things and then get upset and stamp your feet if 
>>> they disagree.
>> Nope, not the people - so far you are the first one I've had to argue 
>> on this topic... And aren't you so damn proud of it.
>Huh? Start making some sense. You feel the need to tell people - in this 
>case me - how they should do things. Well sir - go fuck yourself! I will 
>do things I as see fit and you will learn you cannot control others - I 
>guarantee it!

I can feel the dopamine bursts yau had when writing this down. Yes, everyone
has the ability of ignorance and I have long ago learned that most people like
you feed on doing things their way - not because it's a good way but just for
the sake of it - and cant be changed.

Nothing new here, pal.

>>> Man it pisses you off so that people don't puss out and do whatever 
>>> you damn eh?
>> Not really... But you do like to think that way if anyone dares to say 
>> that you are an ignorant prick with bad behaviour, don't you?
>Whenever somebody attempts to tell me how I must behave I tell them the 
>same thing I'm about to tell you - fuck off! I've long since become an 
>adult and I don't need to listen to your silly assed opinion.

Nope, that's not what becoming adult is about :) It's about learning to listen
other peoples opinions, evaluate them and make choices. Did you grow up in
family/environment where having your own opinions had no meaning? That would
explain why that is such a sore spot on you.

>It does 
>piss you off that you cannot control others because you continue to try 
>as evidenced by the fact that you continue to respond in an attempt to 
>convince me of your way of doing things.

No, and...

>You, like others before you, 
>will fail in this regard.

 ...I already know this, but...

>You're not my father nor mother

 ...maybe my guess above hit the bulls eye.

>I don't need to listen to you and I won't. Now you'll 
>eventually have to learn to live with it and deal with it.

You seem to have an image of you having some bigger sort of effect on other
peoples lives because they reply to you and critisize you on network where
they daily reply to dozens or even on hundreds on people and propably
critisize good amount of these people now and then too...

The fact that I argue with you does not make you important - if it did then
'importance' would be suffering really bad inflation. Sorry :)

-- 
***/---   Sir Robin (aka Jani Saksa) Bi-Sex and proud of it!     ---\***
**/  email: robsku@fiveam.NO-SPAM.org, <*> Reg. Linux user #290577   \**
*| Me, Drugs, DooM, Photos, Writings... http://soul.fiveam.org/robsku |*
**\---                 GSM/SMS: +358 44 927 3992                  ---/**
"Kun nuorille opetetaan, että kannabis on yhtä vaarallista kuin heroiini,
niin tokihan he oppivat, että heroiini on yhtä vaaratonta kuin kannabis."


------------------------------

Date: Wed, 11 Jun 2008 12:49:24 +0100
From: José Luis Pérez Diez <jluis@agujeronegro.escomposlinux.org>
Subject: Re: Perl on embedded device
Message-Id: <VA.00000c0b.87eeda97@agujeronegro.escomposlinux.org>

In article <484ef5ef$1_5@news.peopletelecom.com.au>, Andrew Rich wrote:
> Does LINUX and PERL run on small embedded devices ?

>
Yes Perl runs on embedded devices. 

Openembedded http://oe.linuxtogo.org/ has recipes to build perl and get 
it running on most of the machines listed in: 
http://oe.linuxtogo.org/filebrowser/org.openembedded.dev/conf/machine

 



------------------------------

Date: Wed, 11 Jun 2008 13:05:20 +0200
From: swilting <john.swilting@wanadoo.fr>
Subject: please help me for my script
Message-Id: <484fb170$0$870$ba4acef3@news.orange.fr>

i  dont understand my script doesnt execute in apache
perl -c script.pl
syntax ok

perl script.pl
i reponse cool html


#!/usr/bin/perl -w
use diagnostics;
use warnings;
use strict;
use CGI qw(:standard escapeHTML);
use CGI::Carp qw(fatalsToBrowser);
use Net::SMTP;
##use FileHandle;
use File::Copy;
use constant  LONGUEUR_MAX => 5_000;

my $cgi;
my $key;
my %etats;
my $ecran_actuel;

$cgi = new CGI;

%etats = (
    'defaut' =>\&saisie_form,
##    'saisie_code_capcha' =>\&saisie_code_capcha,
##    'validation' =>\&validation,
    );
$ecran_actuel = param(".Etat") || "defaut";
die "Pas d'ecran pour $ecran_actuel" unless $etats{$ecran_actuel};


## engendre le document courant
en_tete_standard();
while ( my ($nom_ecran,$fonction) = each %etats){
    $fonction->($nom_ecran eq $ecran_actuel);
    }

pied_de_page_standard();


########################################################################
##       fonctions d en tete , de pied de page ,de menu ################
########################################################################

sub en_tete_standard {
    print header(),
    print start_html(-Title => "contact" , -BGCOLOR=>"White",
                     -script=>{-type=>'JAVASCRIPT',
                                                           -src=>'code.js'}
    );
        print start_form();
        }

sub menu_boutique{
        print p(vers_doc("annuler"),
                    vers_doc("saisie_code_capcha"));
        }


sub saisie_form {
     my($actif) = @_;
        return unless $actif;
        print "<H1>vous desirez me contacter !</H1>\n";
        print p("remplissez le formulaire suivant !");
         print pre ( p ("Nom\&nbsp;:              ",textfield("Nom")),
                             p
("Adresse\&nbsp;:          ",textfield("Adresse")),
                             p
("Ville\&nbsp;:            ",textfield("Ville")),
                             p ("Code
Postal\&nbsp;:      ",textfield("Code_postal")),
                             p
("Pays\&nbsp;:             ",textfield("Pays")),
                             p
("Telephone\&nbsp;:        ",textfield("Teléphone")),
                             p
("e-mail\&nbsp;:           ",textfield("Mail")),
                             p
("commentaire\&nbsp;:      ",textarea("commentaire"),
                                                    -rows=>10,
                                                    -columns=>50)),
                            p("vous pouvez joindre des images au format gif
(pas obligatoire)\&nbsp;:     ",  filefield(-name=>'upload',
                                                                   -default=>'',
                                                                   -size=>50,
                                                                   -maxlength=>50));
                                
             
        menu_boutique();
        }

sub vers_doc { submit (-NAME => ".Etat", -VALUE => shift) }

sub pied_de_page_standard{ print end_form(),end_html() }


------------------------------

Date: Wed, 11 Jun 2008 08:58:10 -0400
From: Dan Rumney <danrumney@warpmail.net>
Subject: Re: please help me for my script
Message-Id: <484fcbda$0$31762$4c368faf@roadrunner.com>

swilting wrote:
> i  dont understand my script doesnt execute in apache
> perl -c script.pl
> syntax ok
> 
> perl script.pl
> i reponse cool html

Take a look in your apache error logs. You should see some errors in 
there indicating why the script isn't executing.


------------------------------

Date: Wed, 11 Jun 2008 12:56:57 +0000 (UTC)
From: Ben Bullock <benkasminbullock@gmail.com>
Subject: Re: please help me for my script
Message-Id: <g2oi2n$bfc$1@ml.accsnet.ne.jp>

On Wed, 11 Jun 2008 13:05:20 +0200, swilting wrote:

> i  dont understand my script doesnt execute in apache

> sub en_tete_standard {
>     print header(),
                    ^
This "," should be ";".

>     print start_html(-Title => "contact" , -BGCOLOR=>"White",
>                      -script=>{-type=>'JAVASCRIPT',
>                                                            -src=>'code.js'}
>     );

I found this weird bug by running it outside Apache too to see what it
was doing.


------------------------------

Date: Tue, 10 Jun 2008 15:15:31 -0700 (PDT)
From: Bill H <bill@ts1000.us>
Subject: Re: Time and again
Message-Id: <5b076040-4f08-4a55-90ef-dbaf7a434803@25g2000hsx.googlegroups.com>

On Jun 10, 8:10=A0am, markdibley <markdib...@gmail.com> wrote:
> On Jun 10, 12:15=A0pm, Jacob JKW <jacob...@yahoo.com> wrote:
>
> > On Jun 10, 7:09 am, Jacob JKW <jacob...@yahoo.com> wrote:
> > > Check outhttp://search.cpan.org/~drolsky/DateTime-Format-HTTP/
>
> > Sorry make thathttp://search.cpan.org/~gaas/libwww-perl-5.812/lib/HTTP/D=
ate.pm:
>
> > use HTTP::Date;
> > print str2time('Tue Jun 10 11:28:55 2008');
>
> > yields 1213111735
>
> Thank you sooooo much. That is exactly what I was looking for.
>
> Below is an outline of all the outputs I have tried
>
> #!/usr/bin/perl -w
>
> use strict;
> use Time::Local ;
> use HTTP::Date;
>
> print localtime();print "\n";
> print localtime(),"\n";
> print scalar localtime();print "\n";
> print localtime()."\n";
> print localtime(time)."\n";
> print time()."\n";
> print timelocal(localtime())."\n";
> #print timelocal(scalar localtime())."\n"; =A0 =A0doesn't work
> print str2time(scalar localtime())."\n";
> print str2time('Tue Jun 10 11:28:55 2008')."\n";
> exit;
>
> gives
>
> 28141310510821611
> 28141310510821611
> Tue Jun 10 13:14:28 2008
> Tue Jun 10 13:14:28 2008
> Tue Jun 10 13:14:28 2008
> 1213100068
> 1213100068
> 1213100068
> 1213093735
>
> where the last number is different because it is from an earlier time
> string.
>
> Now, when I forget and I search for "convert localtime string into
> timestamp" I will hopefully find this. Google is my notebook ;-)
>
> Thanks again
>
> Mark

If you are printing localtime() to a file so that it is readable and
know that you are going to want to sort it later, why not just do

print qq~localtime()|time()~;

(replace the '|' with your delimiter of choice)

and then you have the converted sortableversion of localtime() in the
file also and no need to convert localtime() back in the future?

Bill H


------------------------------

Date: Tue, 10 Jun 2008 19:27:25 -0500
From: Tad J McClellan <tadmc@seesig.invalid>
Subject: Re: Time and again
Message-Id: <slrng4u6vd.37b.tadmc@tadmc30.sbcglobal.net>

Bill H <bill@ts1000.us> wrote:

> If you are printing localtime() to a file so that it is readable and
> know that you are going to want to sort it later, why not just do
>
> print qq~localtime()|time()~;


Did you try that code before posting it?

 ...

I didn't think so.


-- 
Tad McClellan
email: perl -le "print scalar reverse qq/moc.noitatibaher\100cmdat/"


------------------------------

Date: Wed, 11 Jun 2008 07:32:43 -0400
From: zentara <zentara@highstream.net>
Subject: Re: Tk with Thread
Message-Id: <krdv44p9p64q4hr06jdlct9bej34uu09ku@4ax.com>

On Tue, 10 Jun 2008 13:30:58 -0700 (PDT), Slickuser
<slick.users@gmail.com> wrote:

>How would I go fixing my code below to make it work?
>
>I am just frustrate that I can't get it to work and not any example
>toward to this issue. Thanks.

This dosn't use any win32 stuff, but shows how to do it. When you
add in your excel stuff, put the results in a shared variable, and read
it in the timer.

#!/usr/bin/perl
use strict;
use warnings;
use Tk;
use threads;
use threads::shared;

my $data:shared = '';
my $go_control:shared = 0;
my $die_control:shared = 0;

#create thread before any Tk
my $thr = threads->new(\&excecute);


my $mainWindow = MainWindow->new;

my $textBox = $mainWindow->Scrolled("Text", -width=>80, -height=>7,
      -scrollbars=>"ose", -wrap=>"word")->pack();

my $goBut; # need to declare here so can be used in -command
$goBut = $mainWindow->Button(-foreground=>"blue", -text=>"Click",
                   -command=>sub {
$goBut->configure(-state=>"disabled");

$textBox->configure(-state=>"normal");
				   $go_control = 1; #start thread
				   } )->pack();

my $stopBut = $mainWindow->Button(-foreground=>"red", -text=>"Exit",
                   -command=>sub{  $die_control = 1;
				   $thr->join;    
				   exit;
				   })->pack();

#use a timer to read the shared variable and deal with Tk stuff

my $repeater = $mainWindow->repeat(20,sub{
                
                $textBox->insert('end',$data);
                $textBox->see('end');


             });


MainLoop;


sub excecute{
   
#   require Win32::OLE;
#   require Win32::OLE::Const 'Microsoft Excel';
   
   while(1){
      
      #wait for $go_control  
      if($go_control){      
           open(FILE,$0 ) or die "Can't open file.\n";
             while(<FILE>){
              if($die_control){return} 
              $data = $_;
	     }
	   close(FILE);
     }else{ select(undef,undef,undef,.25); }# sleep until awakened 
   }
	
return;
}

__END__

zentara


-- 
I'm not really a human, but I play one on earth.
http://zentara.net/CandyGram_for_Mongo.html 


------------------------------

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 V11 Issue 1631
***************************************


home help back first fref pref prev next nref lref last post