[28276] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 9640 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Aug 23 21:05:50 2006

Date: Wed, 23 Aug 2006 18:05: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, 23 Aug 2006     Volume: 10 Number: 9640

Today's topics:
    Re: Calling another cgi program using CGI.pm <tadmc@augustmail.com>
    Re: Failure with perl2exe <kevin@vaildc.net>
    Re: how can I find the driver list in perl <bik.mido@tiscalinet.it>
    Re: how can I find the driver list in perl <xicheng@gmail.com>
    Re: how can I find the driver list in perl <bik.mido@tiscalinet.it>
    Re: how can I find the driver list in perl <justin.0607@purestblue.com>
    Re: how can I find the driver list in perl <tadmc@augustmail.com>
    Re: how can I find the driver list in perl <mgarrish@gmail.com>
    Re: Most useful standard module? (Jamie)
    Re: Multiple copies of perl <benmorrow@tiscali.co.uk>
    Re: Permission denied trying to execute shell commands  <benmorrow@tiscali.co.uk>
    Re: Permission denied trying to execute shell commands  <glennj@ncf.ca>
    Re: Question about UNIVERSAL <bik.mido@tiscalinet.it>
    Re: Reg. Exp. Question: How to minimally match backward <xicheng@gmail.com>
        Reg. Exp. Question: How to minimally match backwards as <newspost@coppit.org>
        warnings (was Re: Most useful standard module?) <tadmc@augustmail.com>
        xslt ? <surfunbear@yahoo.com>
    Re: xslt ? <john@castleamber.com>
    Re: xslt ? <mgarrish@gmail.com>
    Re: xslt ? <tadmc@augustmail.com>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

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

Date: Wed, 23 Aug 2006 19:07:07 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: Calling another cgi program using CGI.pm
Message-Id: <slrneeprdb.go5.tadmc@magna.augustmail.com>


[ Please do not top-post! }


dmedhora@gmail.com <dmedhora@gmail.com> wrote:

> Lets say if the index.pl program above validates the user/password
> successfully then  how do I continue to another html page?
> say, continue.pl


If continue.pl accepts GET requests, you can issue a "redirect":

   print "Location: http://www.yoursite.com/cgi-bin/continue.pl\n\n";

or some such.



[ snip TOFU]

-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


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

Date: Wed, 23 Aug 2006 23:58:29 GMT
From: Kevin Michael Vail <kevin@vaildc.net>
Subject: Re: Failure with perl2exe
Message-Id: <kevin-72685A.19582823082006@news.verizon.net>

In article <m2hd0fe4p2.fsf@Sherm-Pendleys-Computer.local>,
 Sherm Pendley <sherm@Sherm-Pendleys-Computer.local> wrote:

> "MoshiachNow" <lev.weissman@creo.com> writes:
> 
> > Running perl2exe gives warniing.
> > An executable is created,however it closes immediately with some
> > warning that I'm not able to grasp ...too fast...
> >
> > perl2exe nettestTk.pl
> >
> > Perl2Exe V8.70 Copyright (c) 1997-2005 IndigoSTAR Software
> > Registered to Lev Weissman:levcreo:20060214
> > Converting 'nettestTk.pl' to nettestTk.exe
> > Warning: Can't locate Mac/InternetConfig.pm
> >     at D:\Perl\lib\Net\Config.pm line 40
> >     @INC = D:\Perl\lib, D:\Perl\site\lib,
> >
> > tried installing Mac::InternetConfig.pm with CPAN and ppm,got errors:
> >
> > cp Carbon.pm blib\lib\Mac/Carbon.pm
> > cp AppleEvents.pm ..\blib\lib\Mac\AppleEvents.pm
> 
> Your script uses Mac::InternetConfig, Mac::Carbon, and Mac::AppleEvents
> modules. What do you hope to accomplish by bundling Mac-only modules into
> a Windows-only .exe file?

Actually, what is happening is that Net::Config will use the 
Mac::InternetConfig module under some circumstances; it probably has a 
"require" in the appropriate conditional context.  However, perl2exe 
isn't smart enough to realize it doesn't need this module and tries to 
include it, and complains when it can't.

To the OP:  ignore the error.  Whatever problem you're having, this 
isn't causing it.  I would recommend contacting IndigoStar, they're very 
good about responding.
-- 
Kevin Michael Vail  | "This is so cool I have to go to the bathroom!"
kevin@vaildc.net    |                   -- Calvin



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

Date: 23 Aug 2006 20:30:29 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: how can I find the driver list in perl
Message-Id: <iq6pe2p2jnqtla29oe1mosvbmld9mlvseo@4ax.com>

On Wed, 23 Aug 2006 15:06:47 GMT, "Jürgen Exner"
<jurgenex@hotmail.com> wrote:

>Over G wrote:
>> What command should I use IN THE PERL LANGUAGE in order  to get the
>> list of available HD in my computer.
>
>I am confused.

Me too. I don't see how shouting parts of an unclear question make it
more clear.

Also I'm not aware of any Perl module for high digestibility. Maybe
there's room for it in the Acme namespace.

However, since I'm generous, I'll try to answer the OP's question:

  perl -e 'system "fdisk -l"'
  perl -e 'system "ls -1 /dev/[sh]d[a-z]"'

He should feel free to play with qx// instead, of course.


Michele
-- 
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
 .'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,


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

Date: 23 Aug 2006 12:59:13 -0700
From: "Xicheng Jia" <xicheng@gmail.com>
Subject: Re: how can I find the driver list in perl
Message-Id: <1156363153.255636.123990@h48g2000cwc.googlegroups.com>

Michele Dondi wrote:
> On Wed, 23 Aug 2006 15:06:47 GMT, "J=FCrgen Exner"
> <jurgenex@hotmail.com> wrote:
>
> >Over G wrote:
> >> What command should I use IN THE PERL LANGUAGE in order  to get the
> >> list of available HD in my computer.
> >
> >I am confused.
>
> Me too. I don't see how shouting parts of an unclear question make it
> more clear.
>
> Also I'm not aware of any Perl module for high digestibility. Maybe
> there's room for it in the Acme namespace.
>
> However, since I'm generous, I'll try to answer the OP's question:
>
>   perl -e 'system "fdisk -l"'
>   perl -e 'system "ls -1 /dev/[sh]d[a-z]"'

'fdisk' may need 'sudo' under Linux, and an alternative way can be

  perl -lne 'm{^/dev/(\S+)} and print $1' /etc/fstab

in some Unixies, the checked file might be '/etc/mnttab' and in a
different format. so a way, if dont want to use CPAN modules, is to
find the right file containing the wanted information and parse it.

Xicheng



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

Date: 23 Aug 2006 22:46:11 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: how can I find the driver list in perl
Message-Id: <hdfpe2506d3sd6921la7rmod8kn2irqee1@4ax.com>

On 23 Aug 2006 12:59:13 -0700, "Xicheng Jia" <xicheng@gmail.com>
wrote:

>> However, since I'm generous, I'll try to answer the OP's question:
>>
>>   perl -e 'system "fdisk -l"'
>>   perl -e 'system "ls -1 /dev/[sh]d[a-z]"'
>
>'fdisk' may need 'sudo' under Linux, and an alternative way can be

I bet that if he were under some flavor of *nix, he wouldn't need to
ask. Indeed it's easy to guess that he's under Win*, with a high
probability of being right. This is no excuse for not saying so in the
first place, and require us to put our esp cap on, instead. I thought
it to be clear enough that these "answers" were intended to be a joke.


Michele
-- 
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
 .'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,


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

Date: Wed, 23 Aug 2006 20:58:01 -0000
From: Justin C <justin.0607@purestblue.com>
Subject: Re: how can I find the driver list in perl
Message-Id: <slrneepg99.44l.justin.0607@moonlight.purestblue.com>

On 2006-08-23, Over G <odperry@gmail.com> wrote:
> excuse me bu t who are you to tell me to piss off. ?

OK, had enough now.

*plonk*

	Justin.

-- 
Justin C, by the sea. 


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

Date: Wed, 23 Aug 2006 18:49:16 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: how can I find the driver list in perl
Message-Id: <slrneepqbs.go5.tadmc@magna.augustmail.com>

Over G <odperry@gmail.com> wrote:
> Tad McClellan wrote:

>> You asked a question that has nothing to do with Perl programming.
>>
>> This is the Perl programming newsgroup you know...
> I will rephrase :
> 
> What command should I use IN THE PERL LANGUAGE in order  to get the
> list of available HD in my computer.
> thanks.


Your question still has nothing to do with Perl programming!

You are looking for the answer in the wrong place (which will make
the answer much much harder to find).


>> Ad hominem attacks such as that indicate a lack of intellect.
> 
> Lack of intellect is someone that can not understand simple question,


I am quite sure that I understand your question better than you do!

Whether you are asking about device drivers or hard disks, the answer
depends on what operating system you are using.

You don't seem to realize that you have an operating system question.


> and prefer to attack with usless Sarcasm.


Knowing what kind of question you have is not at all useless
(if you apply some of that claimed intellect).

First find out how to answer your question for your operating 
system, _then_ turn your attention to how to automate it.

Knowing what needs to be done makes it a lot easer to write
a program that does that...


-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


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

Date: 23 Aug 2006 17:38:05 -0700
From: "Matt Garrish" <mgarrish@gmail.com>
Subject: Re: how can I find the driver list in perl
Message-Id: <1156379885.588352.188090@m73g2000cwd.googlegroups.com>


Over G wrote:

> anno4000@radom.zrz.tu-berlin.de wrote:
> > Over G <odperry@gmail.com> wrote in comp.lang.perl.misc:
> > >
> > > Tad McClellan wrote:
> > > > Over G <odperry@gmail.com> wrote:
> >
> > > > You asked a question that has nothing to do with Perl programming.
> > > >
> > > > This is the Perl programming newsgroup you know...
> > > I will rephrase :
> > >
> > > What command should I use IN THE PERL LANGUAGE in order  to get the
> > > list of available HD in my computer.
> > > thanks.
> >
> > Simple.  There is no such command in the Perl language.
> >
> > Now piss off.
>
> excuse me bu t who are you to tell me to piss off. ?
>

He is what we here call a regular poster. You are not, and you're not
fooling anyone.

> if you lack the knowledge that is required to answer such a question,
> means that you don't know enough perl , please don't answer or save us
> your low enligsh that belong to the red neck.
>

There are so many grammatical problems with that "paragraph" it's not
even funny. If your English is poor, which yours is, you should try
using a spellcheck program before posting. If you could write English
well, your paragraph above might make more sense as follows: (my
comments in brackets)

If you lack the knowledge to answer this question, it must mean you
don't know very much about the language [think what that says about
you!]. If that's the case, please don't answer, or at least spare the
world your red-neck English.

What you wrote, to someone who has spoken English his whole life, is
painful to read. What you wrote in your original post was equally
unclear. Although open to some interpretation, most people would guess
you were asking for what you were asking for: a list of drivers. A list
of drivers is not and never will be the same as a list of drives.
That's your problem for being unclear, not anyone else's.

Matt



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

Date: Wed, 23 Aug 2006 19:24:44 GMT
From: nospam@geniegate.com (Jamie)
Subject: Re: Most useful standard module?
Message-Id: <Lc11563594928500x783ad8@air.tunestar.net>

In <1156326313.349336.168340@b28g2000cwb.googlegroups.com>,
"Davy" <zhushenli@gmail.com> mentions:
>Hi all,
>
>I have used Getopt::Std and File::Find. I found standard module useful.
>
>Is there any artical summarize the most useful standard module?
>
>Best regards,
>Davy

I'd vote for: 

#1 Data::Dumper

I also really like IO::File and IO::Handle I know there are many other ways to
work with file handles, but to me, the IO::* stuff seems to make more sense. If
you get in the habit of only using getline() and close(), you can easily create
your own objects that return text lines w/out having to mess with TIE. I find
this easier, but then, I tend to consider 'tie' to be a bit of a hack. Others
will disagree, which is fine. 

It really is a matter of style:

I tend to think of 'strict' and 'warnings' as more programming
pragmas that happen to work with 'use'. But, since others are addressing
warnings and strict, I'll add my two bits.

Personally, I *really* like 'use strict'. 

I do make use of the -w switch now and then when trying to diagnose something,
but I'm not to big on 'use warnings'. Data::Dumper is my friend and to me
anyway, far more useful when figuring out problems.

Granted, working in a group setting where the other members have proclaimed
though shalt use warnings and I'm quite open and comfortable with it. (Next time
I do something, I might check to see if 'use warnings' will warn me about objects
not being cleaned up at the end. THAT would be a useful warning.)

When I'm on my own, I just don't see the value of it when creative use of
Data::Dumper almost always finds problems without finding lots of non-problems.

Varies with case-to-case, standard disclaimers apply, don't jump down my throat
I do agree there are times when -w *is* useful.  Saying anything to the
contrary of 'warnings' usually gets you arrested by the perlice...

Jamie
-- 
http://www.geniegate.com                    Custom web programming
guhzo_42@lnubb.pbz (rot13)                User Management Solutions


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

Date: Tue, 22 Aug 2006 21:01:34 +0100
From: Ben Morrow <benmorrow@tiscali.co.uk>
Subject: Re: Multiple copies of perl
Message-Id: <ud4sr3-cqs.ln1@osiris.mauzo.dyndns.org>


Quoth rashmiek@gmail.com:
> 
> I am struck with a problem.I have a perl script that takes UART port
> number as a command line input. Using this input the same perl script
> will have to be run on different hardware platforms.

You can do cross-platform serial port stuff with Win32::SerialPort and
Device::SerialPort.

> Basically, I want to execute multiple copies of the same perl script.
> Not sure how to achieve this.

Err... fork?

I don't understand what you are asking for. Please specify your problem
more clearly.

Ben

-- 
"Awww, I'm going to miss her."
"Don't you hate her?"
"Yes, with a fiery vengeance."
                                                  [benmorrow@tiscali.co.uk]


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

Date: Tue, 22 Aug 2006 20:56:18 +0100
From: Ben Morrow <benmorrow@tiscali.co.uk>
Subject: Re: Permission denied trying to execute shell commands from Perl/CGI.
Message-Id: <244sr3-cqs.ln1@osiris.mauzo.dyndns.org>


Quoth oleg106@yahoo.com:
> Hi,
> 
> I just installed Apache and I am trying to call a script that should
> output some stuff to my browser.  I can't get this to work at all.
> 
> Simple script
> 
> #! /usr/bin/perl -w
    ^
You don't want this space.

You want
    use warnings;
instead of -w.

You want
    use strict;

Have you read the Posting Guidelines?

> print "Content-type:text/html\n\n";

It's not nice to lie. The output of ls(1) is not HTML, so don't pretend
it is.

In any case, you should provide a charset parameter for text/
content-types. Not doing so can lead to invoking browser bugs.

> print `ls`;
> 
> The screen is blank.  httpd logs indicate permission denied ...
> 
> [Tue Aug 22 14:54:32 2006] [error] [client 172.25.31.80] ls: .,
> referer: http://salrhellog01/maillog/
> [Tue Aug 22 14:54:32 2006] [error] [client 172.25.31.80] : Permission
> denied, referer: http://host/log/
> 
> Any idea?  The script works just fine locally, but not via the web.  I
> tried exec and system, same deal.  User nobody has access to everything
> it needs.

Well, my initial guess would be that (for some reason) your web server
user doesn't have read permission on the current directory. What happens
if you run the script as the right user from the right directory?

Ben

-- 
   Razors pain you / Rivers are damp
   Acids stain you / And drugs cause cramp.                    [Dorothy Parker]
Guns aren't lawful / Nooses give
  Gas smells awful / You might as well live.            benmorrow@tiscali.co.uk


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

Date: 23 Aug 2006 22:35:24 GMT
From: Glenn Jackman <glennj@ncf.ca>
Subject: Re: Permission denied trying to execute shell commands from Perl/CGI.
Message-Id: <slrneepm1c.2a3.glennj@smeagol.ncf.ca>

At 2006-08-22 03:56PM, "Ben Morrow" wrote:
> > #! /usr/bin/perl -w
>      ^
>  You don't want this space.

Nothing wrong with spaces there.  See exec(2)

-- 
Glenn Jackman
Ulterior Designer


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

Date: 23 Aug 2006 20:14:27 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: Question about UNIVERSAL
Message-Id: <em6pe25d07t1ljpdvum9f9nen400qg17mh@4ax.com>

On Wed, 23 Aug 2006 18:30:12 +0200, "Ferry Bolhar"
<bol@adv.magwien.gv.at> wrote:

>You may be right but if I do not attempt to learn somewhat new
>from time to time (and often other code contains some very useful
>techniques), I will never use Perl in all the ways it is useable. The

Chances are you will never use Perl in all the ways it is usable
anyway! :-)


Michele
-- 
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
 .'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,


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

Date: 23 Aug 2006 13:05:18 -0700
From: "Xicheng Jia" <xicheng@gmail.com>
Subject: Re: Reg. Exp. Question: How to minimally match backwards as well as forwards?
Message-Id: <1156363518.912314.126630@p79g2000cwp.googlegroups.com>


David Coppit wrote:
> Hi all,
>
> I have a quick question about regular expressions. Is there any way to write an
> expression such that the match doesn't also have a substring (other than the
> entire match) that matches?
>
> The context is this: I'm trying to match the "^From " at the start of an email
> in an mbox. However, sometimes MUA's fail to escape "^From " that appears
> within the body of an email. The current pattern I'm using is:
>
>    (?-xism:(?x)^
>      (From\s
>        # Skip names, months, days
>        (?> [^:]+ )
>        # Match time
>        (?: :\d\d){1,2}
>        # Match time zone (EST), hour shift (+0500), and-or year
>        (?: \s+ (?: [A-Z]{2,6} | [+-]?\d{4} ) ){1,3}
>        # smail compatibility
>        (\sremote\sfrom\s.*)?
>      ))
>

you could be more specific with your pattern, like change

    (?> [^:]+ )

to

     (?> [^:\n]+ )

then this sub-pattern will not match over lines. So to be more
specific, you will be more possibly reach your solution.
i.e. add '@' into your pattern, since there is at least one email
address in the 'From' field.

Good luck,
Xicheng



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

Date: 23 Aug 2006 15:24:49 EDT
From: David Coppit <newspost@coppit.org>
Subject: Reg. Exp. Question: How to minimally match backwards as well as forwards?
Message-Id: <Pine.BSF.4.64.0608231531220.84372@www.provisio.net>

Hi all,

I have a quick question about regular expressions. Is there any way to write an
expression such that the match doesn't also have a substring (other than the
entire match) that matches?

The context is this: I'm trying to match the "^From " at the start of an email
in an mbox. However, sometimes MUA's fail to escape "^From " that appears
within the body of an email. The current pattern I'm using is:

   (?-xism:(?x)^
     (From\s
       # Skip names, months, days
       (?> [^:]+ )
       # Match time
       (?: :\d\d){1,2}
       # Match time zone (EST), hour shift (+0500), and-or year
       (?: \s+ (?: [A-Z]{2,6} | [+-]?\d{4} ) ){1,3}
       # smail compatibility
       (\sremote\sfrom\s.*)?
     ))

But when running this on the following (shortened) mailbox:

   From linux-users-owner@it.canterbury.ac.nz  Wed Feb 15 10:35:14 2006
   [snip headers and most of body]

   This line and the next is part of the first email's signature.
   From this principle, all of life and physics may be deduced.

   From linux-users-owner@it.canterbury.ac.nz  Wed Feb 15 11:35:09 2006
   [snip headers and most of body]

it matches the start of the first email, but incorrectly matches the string
"From this principle, all of life and physics may be deduced.\n\nFrom linux-users-owner@it.canterbury.ac.nz  Wed Feb 15 11:35:09 2006".

Unfortunately I must assume that newlines can appear in the header, so I can't
change "[^:]" to "[^:\n]". Modifying the matches to be minimal with "?" doesn't
help either. How can I make the match "minimal" with respect to the start of
the match, other than testing $1 and resetting pos if $1 contains a matching
substring?

Thanks,
David


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

Date: Wed, 23 Aug 2006 19:29:45 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: warnings (was Re: Most useful standard module?)
Message-Id: <slrneepsnp.go5.tadmc@magna.augustmail.com>


Jamie <nospam@geniegate.com> wrote:

> I do make use of the -w switch now and then when trying to diagnose something,
> but I'm not to big on 'use warnings'. 


"use warnings" is far superior to the -w switch.


> Data::Dumper is my friend and to me
> anyway, far more useful when figuring out problems.


Some people want a friend that helps them _discover_ problems too...


> When I'm on my own, I just don't see the value of it 


If you should, heaven forbid, ever have a "warnable" bug in your 
program, then without warnings you silently get the wrong output 
while with warnings you noisily get the wrong output.

I like to _know_ when I'm getting the wrong output. I suppose some
people would rather let the customer find it rather than a machine?


> Data::Dumper almost always finds problems 


Discovering bugs and diagnosing bugs are apples and oranges.

(D::D is one of my favorite modules too, I've often wondered why
 it is not mentioned in the "usual"[1] data structure pods.
)


> without finding lots of non-problems.


Warnings don't often find non-problems in my code.

You must be doing something differently.


> Varies with case-to-case, standard disclaimers apply, don't jump down my throat


I hope this followup sounds like countering your bad advice rather
than throat-jumping...


> I do agree there are times when -w *is* useful.  


("use warnings" is far superior to the -w switch.)


Then why not take advantage of its usefulness?

Do you _like_ finding the bugs yourself rather than having a
machine find them for you?


> Saying anything to the
> contrary of 'warnings' usually gets you arrested by the perlice...


warnings are like seat belts.

If you don't get in an accident, then you don't need them.

The Police are just trying to save you potential pain. 

Thank them, and buckle up!



[1] perlreftut.pod perlref.pod perllol.pod perldsc.pod.

-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


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

Date: 23 Aug 2006 13:07:35 -0700
From: "surf" <surfunbear@yahoo.com>
Subject: xslt ?
Message-Id: <1156363655.740379.139370@p79g2000cwp.googlegroups.com>


 I had tried to work with XLST a few years ago. I got some simple stuff
to work, then I started playing with perl XML parsers and the xml:twig
module in perl. All of this stuff I really liked, so I forgot about
working with xlst which to me didn't seem like the way to go,
especially if it got very complex. I'm not sure why anyone would want
to write a program of any sort in XML anyway ?

 However, now I realize I have to know what to say in an interview. A
recruiter did a phone interview with me and asked me about xlst. I told
him I thought it was rather weak compared to what perl modules can do,
but if I had to do it, I've played with it and have a book on it. I
perhaps have to figure out how to answer these kinds of questions, or
ask myself do I really want to have to write XSLT anyway if they did
hire me someplace that expects you to do it that way ?



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

Date: 23 Aug 2006 20:36:09 GMT
From: John Bokma <john@castleamber.com>
Subject: Re: xslt ?
Message-Id: <Xns98289EB7228E2castleamber@130.133.1.4>

"surf" <surfunbear@yahoo.com> wrote:

>  However, now I realize I have to know what to say in an interview. A
> recruiter did a phone interview with me and asked me about xlst. I told
> him I thought it was rather weak compared to what perl modules can do,
> but if I had to do it, I've played with it and have a book on it. I
> perhaps have to figure out how to answer these kinds of questions, or
> ask myself do I really want to have to write XSLT anyway if they did
> hire me someplace that expects you to do it that way ?

There is no simple answer, sometimes XSLT is better and sometimes Perl. 
Only when you learn both you are able to answer questions like when one is 
better compared to the other. I do recommend to learn XSLT.

-- 
John                Experienced Perl programmer: http://castleamber.com/

          Perl help, tutorials, and examples: http://johnbokma.com/perl/


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

Date: 23 Aug 2006 13:45:23 -0700
From: "Matt Garrish" <mgarrish@gmail.com>
Subject: Re: xslt ?
Message-Id: <1156365919.936347.121760@i42g2000cwa.googlegroups.com>


surf wrote:

> I had tried to work with XLST a few years ago. I got some simple stuff
> to work, then I started playing with perl XML parsers and the xml:twig
> module in perl. All of this stuff I really liked, so I forgot about
> working with xlst which to me didn't seem like the way to go,
> especially if it got very complex. I'm not sure why anyone would want
> to write a program of any sort in XML anyway ?
>

You're so behind the times. Everyone is using RXParse for their XML
these days. Be sure and tell your recruiter.

Matt



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

Date: Wed, 23 Aug 2006 18:56:00 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: xslt ?
Message-Id: <slrneepqog.go5.tadmc@magna.augustmail.com>

surf <surfunbear@yahoo.com> wrote:


> I'm not sure why anyone would want
> to write a program of any sort in XML anyway ?


One Reason:

   XSLT is optimized for machines rather than for humans.



Let's haul this back on-topic:

Contrast that with Perl, which is optimized for humans at the
expense of the machine (throwing cycles and memory at a problem).


-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


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

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 9640
***************************************


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