[8844] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 2461 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Apr 30 03:27:31 1998

Date: Thu, 30 Apr 98 00:00:50 -0700
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Thu, 30 Apr 1998     Volume: 8 Number: 2461

Today's topics:
    Re: 4 digit year and localtime (Craig Berry)
    Re: 4 digit year and localtime <grinch@whoville.com>
    Re: convert an @array into a single $variable? (Craig Berry)
    Re: Defending Perl <metcher@spider.herston.uq.edu.au>
    Re: GetOpts::Std and use strict <rootbeer@teleport.com>
    Re: How to do sort -u within perl? <bbobb@we.be.catchin.spamz.at.europa.com>
    Re: http Reg Exp <tchrist@mox.perl.com>
    Re: http Reg Exp <dformosa@st.nepean.uws.edu.au>
    Re: http Reg Exp <rjk@coos.dartmouth.edu>
    Re: http Reg Exp <aas@sn.no>
        need help BUILDING latet PERL on Unix <wartelld@pilot.msu.edu>
    Re: NEED HELP WITH SYNTAX (Martien Verbruggen)
        pass Hash from C to Perl <jason@itrade.net>
    Re: perl and Year 2000 (Martien Verbruggen)
    Re: Perl for Win32 not writing to file <metcher@spider.herston.uq.edu.au>
        perl guts <bruce@scientia.com.au>
        Perl, COM/DCOM and MTS? (Wesley M. Conner)
        perl_eval_sv("use module;") segmentation fault (SEGV) <xxx@xxx.xxx>
        Q: COM vs. Excel AddIns (Tom Vrankar)
    Re: Q: COM vs. Excel AddIns <rootbeer@teleport.com>
        Q: format with included tabulators <Peter.Eismann@med.siemens.de>
    Re: Q: format with included tabulators <rootbeer@teleport.com>
    Re: Script to parse HTML, converting img tags to text <rootbeer@teleport.com>
    Re: Setuid tips aren't working! (Bart Lateur)
    Re: Simple Question regarding dates <sowmaster@juicepigs.com>
    Re: Thank you Solutionsoft <mhchau@cse.cuhk.edu.hk>
    Re: Toggling reverse on and off on in a for loop <rjk@coos.dartmouth.edu>
    Re: You people want Perl to be popular? <$_=qq!fearless\@NOSPAMio.com!;y/A-Z//d;print>
        Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)

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

Date: 30 Apr 1998 04:12:29 GMT
From: cberry@cinenet.net (Craig Berry)
Subject: Re: 4 digit year and localtime
Message-Id: <6i8tnd$dt6$2@marina.cinenet.net>

kevin scott (kevscott@juno.com) wrote:
: Is there a way to get perl to return a 4 digit year from the operating
: system?
: 
: The only solution I know of is to parse the output of an external
: program such as the UNIX program date..

How is going to all the trouble of parsing external program output easier 
than

   my $fullYear = (localtime)[5] + 1900;

?

---------------------------------------------------------------------
   |   Craig Berry - cberry@cinenet.net
 --*--    Home Page: http://www.cinenet.net/users/cberry/home.html
   |      Member of The HTML Writers Guild: http://www.hwg.org/   
       "Every man and every woman is a star."


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

Date: Wed, 29 Apr 1998 23:27:02 -0400
From: "Grinch" <grinch@whoville.com>
Subject: Re: 4 digit year and localtime
Message-Id: <6i8q3e$45k@fridge.shore.net>

Charles Kerekes wrote in message <6i8oe6$8dc$1@usenet11.supernews.com>...

>The two lines of code will do that for you. In Perl the year given by local
>time is NOT the last two digits but the number of years since year 1900.

I hope it's a 32-bit integer, then. If it's 16-bit, we'll be facing a year
34,668 bug.

Tom, will Perl version 8869.97_0134 be affected by this bug? Will I need to
upgrade to patchlevel 135?

;-)

-grinch

--
-----
"It's not real coffee unless the sugar cubes float." - me

Sherm Pendley
grinch@whoville.com
http://www.whoville.com





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

Date: 30 Apr 1998 03:55:47 GMT
From: cberry@cinenet.net (Craig Berry)
Subject: Re: convert an @array into a single $variable?
Message-Id: <6i8so3$dt6$1@marina.cinenet.net>

Bryan T Hoch (bth@acsu.buffalo.edu) wrote:
: 	Hi, does any one know how to take the seperate elements of an
: array an pass them all as a string into a single variable?

perldoc -f join

---------------------------------------------------------------------
   |   Craig Berry - cberry@cinenet.net
 --*--    Home Page: http://www.cinenet.net/users/cberry/home.html
   |      Member of The HTML Writers Guild: http://www.hwg.org/   
       "Every man and every woman is a star."


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

Date: Thu, 30 Apr 1998 14:44:59 +1000
From: Jaime Metcher <metcher@spider.herston.uq.edu.au>
Subject: Re: Defending Perl
Message-Id: <354801CB.57C95063@spider.herston.uq.edu.au>

Win32 - download binary distribution - type one command - agree to
everything - toast Sarathy in fine Cabernet Sauvignon - back to work.

--

Jaime Metcher (extremely un-guru-like, but productive nonetheless)

Abby Franquemont wrote:
> 
> In article <6i58jn$68r$1@client3.news.psi.net>,
> Abigail <abigail@fnx.com> wrote:
> >
> >I'm not denying Configure is useful. It is. It just makes installation
> >more difficult.
> 
> I think it certainly can, if you're used to doing things the old-
> fashioned way. That's just probably a minority perspective anymore.
> 
> --
> Abby Franquemont        Nothing cures insomnia like the realization
> J. Random BOFH          that it's time to get up. --Fortune program


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

Date: Thu, 30 Apr 1998 05:43:41 GMT
From: Tom Phoenix <rootbeer@teleport.com>
To: Michael mortensen <mikemort@cadence.com>
Subject: Re: GetOpts::Std and use strict
Message-Id: <Pine.GSO.3.96.980429221312.10138E-100000@user2.teleport.com>

On Wed, 29 Apr 1998, Michael mortensen wrote:

> If I do "use strict" with getopts, then the variables
> associated with the flags (such as $opt_v) give compile
> time errors since they are not declared, but if I declare
> them using "my" then it hides the getopts values of
> those variables.
> 
> Is there a way of using getopts while still being able
> to have "use strict"?

These variables are actually globals; you can use 'use vars' to declare
them. Hope this helps! 

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



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

Date: 29 Apr 1998 21:51:06 GMT
From: Todd Santos <bbobb@we.be.catchin.spamz.at.europa.com>
Subject: Re: How to do sort -u within perl?
Message-Id: <6i87ca$hjp$4@supernews.com>

In alt.2600 David Lee Lambert <davidl@pfaffben.user.msu.edu> wrote:
# What's a simple way to do the equivalent of 'sort -u' on a list in perl?


man perlfunc. comp.lang.perl.misc.


-- 
_  _/ __/ $rem=IO::Socket::INET->new(PeerPort=>80,PeerAddr=>"www.europa.com",
  /_\ \   Proto=>"tcp");select($rem); printf("GET /~bbobb\n");select(STDOUT);
_//___/   while(<$rem>){printf($_);}&poof;sub poof {die("--------------\n");}


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

Date: 30 Apr 1998 02:52:16 GMT
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: http Reg Exp
Message-Id: <6i8p10$ee1$1@csnews.cs.colorado.edu>

 [courtesy cc of this posting sent to cited author via email]

In comp.lang.perl.misc, 
:These are not URLs.  urls start with <URL: and end with a >

Really?  How come netscape, lynx, mosaic, and lwp all fail to handle
them then?   More importantly, what schema type is URL: supposed to be?

--tom
-- 
	Tom Christiansen	tchrist@jhereg.perl.com


"All things are possible, but not all expedient."  (in life, UNIX, and perl) -me


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

Date: 29 Apr 1998 23:44:22 GMT
From: ? the platypus {aka David Formosa} <dformosa@st.nepean.uws.edu.au>
Subject: Re: http Reg Exp
Message-Id: <893893462.449299@cabal>

In <6i3et4$f2r$4@comdyn.comdyn.com.au> mgjv@comdyn.com.au (Martien Verbruggen) writes:

>If you hadn't conveniently snipped the examples I put in my post, you
>would have known what I meant. How do you extract the following URLs?

>URL1: http://myserver.com/dir/file.
>URL2: http://myserver.com/dir/file

These are not URLs.  urls start with <URL: and end with a >


--
I'm a perl programer if you need perl programing hire me. 
Please excuse my spelling as I suffer from agraphia see the url. Support NoCeM
http://www.cit.nepean.uws.edu.au/~dformosa/Spelling.html  http://www.cm.org/ 
I'm sorry but I just don't consider 'because its yucky' a convincing argument


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

Date: Wed, 29 Apr 1998 21:18:50 -0400
From: Ronald J Kimball <rjk@coos.dartmouth.edu>
Subject: Re: http Reg Exp
Message-Id: <3547D17A.D3CE6B0A@coos.dartmouth.edu>

? the platypus {aka David Formosa} wrote:
> 
> >URL1: http://myserver.com/dir/file.
> >URL2: http://myserver.com/dir/file
> 
> These are not URLs.  urls start with <URL: and end with a >

That seems rather like saying peanut butter is not peanut butter unless it's
in a jar.

-- 
 _ / '  _      /         - aka -             rjk@coos.dartmouth.edu
( /)//)//)(//)/(    Ronald J. Kimball           chipmunk@m-net.arbornet.org
    /                                   http://www.ziplink.net/~rjk/
        "It's funny 'cause it's true ... and vice versa."


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

Date: 30 Apr 1998 07:07:38 +0200
From: Gisle Aas <aas@sn.no>
Subject: Re: http Reg Exp
Message-Id: <m3yawnc2xx.fsf@furu.g.aas.no>

Tom Christiansen <tchrist@mox.perl.com> writes:

> In comp.lang.perl.misc, 
> :These are not URLs.  urls start with <URL: and end with a >
> 
> Really?  How come netscape, lynx, mosaic, and lwp all fail to handle
> them then?

Not strictly true as LWP does handle them.  URI::URL->new will strip
off any /^<(?:URL:)?(.*)>$/ wrapper before it start parsing.

-- 
Gisle Aas


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

Date: Thu, 30 Apr 1998 01:40:20 -0400
From: "David" <wartelld@pilot.msu.edu>
Subject: need help BUILDING latet PERL on Unix
Message-Id: <6i932f$5ik$1@msunews.cl.msu.edu>

I am attempting to build the latest stable copy of perl on a Unix box
running BSDOS 3.1 using gcc When running make I get the following error:

ares% make
`sh  cflags libperl.so miniperlmain.o` -fPIC miniperlmain.c
          CCCMD =  gcc -DPERL_CORE -c
miniperlmain.c:15:invalid character '[' in first operand
miniperlmain.c:16:invalid character '@' in first operand
miniperlmain.c:18:invalid character '@' in first operand
miniperlmain.c:20:invalid character '@' in first operand
miniperlmain.c:23:invalid character '@' in first operand
miniperlmain.c:25:invalid character '@' in first operand
miniperlmain.c:27:invalid character '@' in first operand
miniperlmain.c:31:invalid character '@' in first operand
miniperlmain.c:35:invalid character '@' in first operand
miniperlmain.c:38:invalid character '@' in first operand
miniperlmain.c:40:invalid character '@' in first operand
miniperlmain.c:48:invalid character '@' in first operand
miniperlmain.c:51:invalid character '@' in first operand
miniperlmain.c:54:invalid character '@' in first operand
miniperlmain.c:60:invalid character '@' in first operand
miniperlmain.c:63:invalid character '@' in first operand
miniperlmain.c:68:invalid character '@' in first operand
miniperlmain.c:71:invalid character '@' in first operand
miniperlmain.c:73:invalid character '@' in first operand
miniperlmain.c:76:invalid character '@' in first operand
miniperlmain.c:80:invalid character '@' in first operand
*** Error code 1

Stop.

If anybody has any ideas I would greatly appreciate the help.

Thank You,
David Wartell
wartelld@pilot.msu.edu





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

Date: 29 Apr 1998 23:52:00 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: NEED HELP WITH SYNTAX
Message-Id: <6i8ef0$s36$4@comdyn.comdyn.com.au>

In article <x7yawob5r2.fsf@sysarch.com>,
	Uri Guttman <uri@sysarch.com> writes:

> also you should not use all upper case in variable names, it is pood
> perl style. and you should clean up your formatting a little, it would

pood? Is that poor or good? :) I think it's perfectly goor perl style,
myself. :)

Martien
-- 
Martien Verbruggen                      |
Webmaster www.tradingpost.com.au        | "In a world without fences,
Commercial Dynamics Pty. Ltd.           |  who needs Gates?"
NSW, Australia                          |


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

Date: Wed, 29 Apr 1998 19:04:25 -0800
From: "Jason He" <jason@itrade.net>
Subject: pass Hash from C to Perl
Message-Id: <6i8mb7$3ac$1@news1.phx.genuity.net>

does anyone know how to pass a hash from C to Perl ?

thanks

-jason




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

Date: 29 Apr 1998 23:43:48 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: perl and Year 2000
Message-Id: <6i8dvk$s36$2@comdyn.comdyn.com.au>

In article <35477C79.28C4F5CA@newbridge.com>,
	Shawn Abigail <sabigail@newbridge.com> writes:
> Hi,
> 
> I am using perl 5.004 as a tool on my workstation. My boss wants to know
> if it is Year 2000 compliant.  What do I tell her?  I haven't seen
> anything on the web about this.  Assuming that my operating system is
> compliant, are there any Y2K issues with perl?  Thanks!

*groan*. Not again...

- Do a search on www.dejanews.com (~g comp.lang.perl.misc & y2k)

- Go to http://www.perl.com/. On that page, there is a BIG header,
  saying: "Does Perl Have a Year 2000 Problem?". Follow that link.
  Also send it to your boss. Maybe that will finally stop them asking
  these boring questions.

Exactly WHERE on the web did you look?

Martien
-- 
Martien Verbruggen                      |
Webmaster www.tradingpost.com.au        | "In a world without fences,
Commercial Dynamics Pty. Ltd.           |  who needs Gates?"
NSW, Australia                          |


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

Date: Thu, 30 Apr 1998 14:35:21 +1000
From: Jaime Metcher <metcher@spider.herston.uq.edu.au>
Subject: Re: Perl for Win32 not writing to file
Message-Id: <3547FF89.81DBE240@spider.herston.uq.edu.au>

Jonathan Stowe wrote:
> 
> On Wed, 29 Apr 1998 10:52:13 -0300, Gilberto Mautner wrote :
> 
> <snip>
> 
> >use CGI;
> >$query = new CGI;
> >$SAIDA = ">>OUTPUT2.TXT";
> >open(SAIDA);
> 
> Aieee.  I think you might want:
> open(SAIDA,$SAIDA) || die "Cant open the file - $!";
> 
snip

The "|| die..." is right and good as all can see, but in changing "open
(SAIDA)" to "open (SAIDA,$SAIDA)", are you deprecating the open(SAIDA)
shorthand?

-- 
Jaime Metcher


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

Date: Thu, 30 Apr 1998 15:58:56 +1000
From: Bruce Woodward <bruce@scientia.com.au>
Subject: perl guts
Message-Id: <35481320.22B913B7@scientia.com.au>

Greetings,

perl has a function av_fetch, in av.c, which returns a given element of
an array. It seems that arrays, in perl are made of linked lists. It
also looks like this function loops through the array until it come to
the desired element number. Is this correct?

thansk,
Bruce

bruce@scientia.com.au



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

Date: Thu, 30 Apr 1998 04:08:21 GMT
From: wesc@ayande.com (Wesley M. Conner)
Subject: Perl, COM/DCOM and MTS?
Message-Id: <3549f92b.118183245@news.erols.com>

	I've been away from the Perl community for a little over a year
and find myself working almost exclusively on NT Server these days. I
know that the Perl/NT community is growing, but don't know if Perl has
been integrated into COM or if the NT implementation supports the
Microsoft DNA architecture.

Question #1
-----------
	Are there any tools for implementing COM/DCOM interfaces using
Perl -- for example, a COM/DCOM IDL to Perl5 translator. I'm interested
in wrapping some existing Perl scripts so as to be callable as COM
components (i.e., probably as a temporary measure).

Question #2
-----------
	Has anyone run across a Perl resource manager for the Microsoft
Transaction Server (MTS) -- for example, something capable of launching
(NT) Perl scripts on pooled threads. If such an animal exists, I'm
guessing it might resemble mod_perl for the Apache server and provide
benefits similar to those MTS provides for low-tech (Visual Basic) COM
components.

	Please copy any affirmative responses to wesc@ayande.com.

Thanks,
Wes

Wesley M. Conner    Ayande Technologies, Inc.
wesc@ayande.com     http://www.ayande.com/


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

Date: Wed, 29 Apr 1998 16:45:57 -0700
From: JDS <xxx@xxx.xxx>
Subject: perl_eval_sv("use module;") segmentation fault (SEGV)
Message-Id: <3547BBB5.F3D2D86C@xxx.xxx>

I would like some help, please, as to how to dynamically load a
package from within C code. Currently I have the following 
(which fails with SEGV).

package dummy.pm:
=================
	package dummy;
 
	require Exporter;
	require DynaLoader;
 
	@ISA = qw(Exporter DynaLoader);
	@EXPORT = qw(dummy_sub);
 
	sub dummy_sub {
        	printf "Subroutine dummy_sub\n";
	}




C code tmp.c:
============

#include <EXTERN.h>
#include <perl.h>

static PerlInterpreter *my_perl;
 
void extern xs_init();
 
 
I32 perl_eval(char *string)
{
        return perl_eval_sv(newSVpv(string,strlen(string)+1),
			G_DISCARD);
}
 
char *embedding[] = { "", "-e", "-w",
        "-I./",
        "0" };
 
 
main (int argc, char **argv, char **env)
{
 
        my_perl = perl_alloc();
        perl_construct( my_perl );
 
        perl_parse(my_perl, xs_init, 5, embedding, NULL);
        perl_run(my_perl);
 
        perl_eval("use dummy;");
 
        perl_call_argv("dummy::dummy_sub();", G_DISCARD, NULL);
 
        perl_destruct(my_perl);
        perl_free(my_perl);
}

xsinit.c  (as created by the Makefile)
=========
#ifdef __cplusplus
extern "C" {
#endif
 
#include <EXTERN.h>
#include <perl.h>
 
#ifdef __cplusplus
}
#  ifndef EXTERN_C
#    define EXTERN_C extern "C"
#  endif
#else
#  ifndef EXTERN_C
#    define EXTERN_C extern
#  endif
#endif
 
EXTERN_C void xs_init _((void));
 
EXTERN_C void boot_DynaLoader _((CV* cv));
 
EXTERN_C void
xs_init()
{
        char *file = __FILE__;
        dXSUB_SYS;
 
        /* DynaLoader is a special case */
        newXS("DynaLoader::boot_DynaLoader", boot_DynaLoader,
		 file);
}


After creating the executable, when executed, the "use dummy" 
successfully loads DynaLoader.pm (you see a msg) and immediately
it dies with Segmentation Fault. Looking at it with the debugger
it dies in the Exporter module.

Any help as to how I can make this work?

thanks,
J.


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

Date: 30 Apr 1998 02:29:39 GMT
From: no@spam.net (Tom Vrankar)
Subject: Q: COM vs. Excel AddIns
Message-Id: <6i8nmj$6t0$1@bashir.ici.net>

I've seen a few references to COM/OLE Automation in this newsgroup. I am 
trying to get something working that I thought was simple, but it eludes me. 
It's probably not even a problem with my perl, but perhaps someone's run into 
this before and could offer a suggestion.

I am using OLE automation to open Excel95/97 and load workbooks. That's all. 
The problem is that one of the workbooks needs functions defined in the 
Analysis ToolPak. For some reason, when dispatching Excel via COM, 
this add-in isn't loaded, even though it loads automatically if 
Excel is started in the usual "manual" ways. How do I force the Analysis 
ToolPak to be loaded?

I've made sure the AddIn's Installed, and have tried to Open the desired 
workbooks with UpdateLinks.

Any ideas would be appreciated.

							twv@ 
-- 
                         ---------------------------------
                                               Tom Vrankar
                                            twv at ici.net
                                 http://home.ici.net/~twv/
                                         Rhode Island, USA



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

Date: Thu, 30 Apr 1998 05:11:39 GMT
From: Tom Phoenix <rootbeer@teleport.com>
To: Tom Vrankar <no@spam.net>
Subject: Re: Q: COM vs. Excel AddIns
Message-Id: <Pine.GSO.3.96.980429221055.10138C-100000@user2.teleport.com>

On 30 Apr 1998, Tom Vrankar wrote:

> For some reason, when dispatching Excel via COM, this add-in isn't
> loaded, even though it loads automatically if Excel is started in the
> usual "manual" ways. How do I force the Analysis ToolPak to be loaded? 

If you're using the proper commands to run another program from perl, but
the other program doesn't cooperate, then it's the other program's fault.
If you're not using the proper commands, then it's your fault. If you
aren't sure about the proper commands, you should read the program's
documentation. If you've read it and you're still not sure, you should ask
in a newsgroup about the program.

Hope this helps!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



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

Date: Thu, 30 Apr 1998 08:02:25 +0200
From: Peter Eismann <Peter.Eismann@med.siemens.de>
Subject: Q: format with included tabulators
Message-Id: <354813F1.11AC@med.siemens.de>

Hallo a,

I need in the 'format' tabulators.
How can I do that?


This works not (with \t)

format MONTH_LIST =
=============================================
@>>>>>>>>>> CHARMs 
$vers
---------------------------------------------
Team\t2\t6\t7\tS(2,6,7)
---------------------------------------------
\t@>>>>>>>>>>\t@######\t@######\t@######
$e,$e1,$e2,$e3
=============================================
 .

Have anybody a idea?

Thanks
Peter Eismann


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

Date: Thu, 30 Apr 1998 06:49:26 GMT
From: Tom Phoenix <rootbeer@teleport.com>
To: Peter Eismann <Peter.Eismann@med.siemens.de>
Subject: Re: Q: format with included tabulators
Message-Id: <Pine.GSO.3.96.980429234219.10138K-100000@user2.teleport.com>

On Thu, 30 Apr 1998, Peter Eismann wrote:

> I need in the 'format' tabulators.

I think you're looking for what we sometimes call "tab stops", often used
for lining up text. 

> This works not (with \t) 
> 
> format MONTH_LIST =
> =============================================
> @>>>>>>>>>> CHARMs 
> $vers
> ---------------------------------------------
> Team\t2\t6\t7\tS(2,6,7)
> ---------------------------------------------
> \t@>>>>>>>>>>\t@######\t@######\t@######
> $e,$e1,$e2,$e3
> =============================================
> .

It looks as if you want to use a series of spaces, instead of a tab
symbol. Of course, the basic idea of a format is that it's a
fill-in-the-blanks template, so you simply make things line up however
you'd like. Maybe something like this: 

format MONTH_LIST =
=============================================
@>>>>>>>>>> CHARMs
$vers
---------------------------------------------
Team              2         6         7   S(2,6,7)
---------------------------------------------
        @>>>>>>>>>>   @######   @######   @######
        $e,           $e1,      $e2,      $e3
=============================================
 .

Although it's not necessary to line up the variables, it makes it
easier to read, to me at least. 

Hope this helps!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/




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

Date: Thu, 30 Apr 1998 05:57:06 GMT
From: Tom Phoenix <rootbeer@teleport.com>
To: Adam <trickett@pacbell.net.nospam>
Subject: Re: Script to parse HTML, converting img tags to text
Message-Id: <Pine.GSO.3.96.980429225123.10138G-100000@user2.teleport.com>

On Thu, 30 Apr 1998, Adam wrote:

> I'm looking for a script that can parse a web page in HTML, and remove
> all <IMG> tags, replacing them with plain text made from the alt tag.
> I've seen them mentioned, but have never been able to track on down. 

There are modules on CPAN which can help you to do this.

    http://cpan.perl.org

> Scripts or ideas accepted, email prefered, Pacbell's News-server is a
> tad bit slow - when it's working.... 

If you want an email reply, put your proper email address into the header
lines, please. 

>  Unsolicited e-mail will be charged a $10 proof reading
>  fee - by replying to this posting you are agreeing to
>  these terms and conditions.

Fortunately, your message said that "ideas" are accepted, so this fee
doesn't apply so long as I have at least one idea in my message, right? Of
course, $10 is exorbitant from someone who thinks that "proof reading" 
should be two words. :-)

Cheers!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



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

Date: Thu, 30 Apr 1998 07:21:52 GMT
From: bart.mediamind@tornado.be (Bart Lateur)
Subject: Re: Setuid tips aren't working!
Message-Id: <35482536.1079221@news.tornado.be>

Nate Grover wrote:

>($<,$>) = ($>,$<);

There is that mystery phrase again. You don't want that, it doesn't do
what you want. It makes you temporarily give up your special rights, so,
at least, don't do that, at least, before you opended the file!

Anyway, here is a code snippet that may help you understanding what is
going on:

   print "Content-type: text/plain\n\n";
   $\="\n";
   print 'UID (from): ',join(":",getpwuid($<));
   print 'UID (to): ',join(":",getpwuid($>));

At least it should show you if the setUID works.

HTH,
Bart.


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

Date: Thu, 30 Apr 1998 00:11:03 -0400
From: Bob Trieger <sowmaster@juicepigs.com>
To: Kris Davey <mivl@inquo.net>
Subject: Re: Simple Question regarding dates
Message-Id: <3547F9D7.6770@juicepigs.com>

Kris Davey wrote:
> 
> I am farly new to PERL and was wondering if someone could show me an
> example of 1. how to display the current date (i.e. 29 April 1998) 2. Store
> it in a scalar variable 3. create a file using the variable so the the file
> is Named 29 April 1998. Any help would be greatly appreciated. I don't know
> if it makes any difference but this script would be run on an NT box. Any
> help would be appreciated. Thanks in advance.

This probably isn't the answer that you are looking for, but you need to
get a book and/or read the online documentation. The questions you have
asked are very basic and anyone that has taken a minute to scan through
"Learning Perl" could answer.


HTH
-- 
Bob Trieger               |  Titanic: big boat, bigger
sowmaster@juicepigs.com   |           iceberg, big deal


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

Date: 30 Apr 1998 01:18:01 GMT
From: Sleep <mhchau@cse.cuhk.edu.hk>
Subject: Re: Thank you Solutionsoft
Message-Id: <6i8jg9$bu4@eng-ser1.erg.cuhk.edu.hk>

Dr. Fridemar Pache <dr.pc@t-online.de> wrote:
> just got your email (attached with the Perl IDE I suppose),
> As I've never dared to open a binary {{un}secure} email-attachment, I
> hesitate to open this marvel. Do you or other readers know a save

hmm...
save it and run on a "isolated" dummy machine ?!


Regards,
Chau.


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

Date: Wed, 29 Apr 1998 21:44:24 -0400
From: Ronald J Kimball <rjk@coos.dartmouth.edu>
Subject: Re: Toggling reverse on and off on in a for loop
Message-Id: <3547D779.BBA24BEB@coos.dartmouth.edu>

Lachlan Dunlop wrote:
> 
> I have a quick question. take the code below,

 ...please!

:-)

> [...]
> Now my question is this is there a way to put the word reverse into a variable
> name say $direction = "reverse" and then the code look like
> 
>     my $i;
> 
>     for $i ($direction @bank) {
>         print $i;
>     }
> 
> So when I want it reversed $direction ="reverse" else $direction = ""

for $i ($reversed ? reverse @bank : @bank) {
    print $;
}

-- 
 _ / '  _      /         - aka -             rjk@coos.dartmouth.edu
( /)//)//)(//)/(    Ronald J. Kimball           chipmunk@m-net.arbornet.org
    /                                   http://www.ziplink.net/~rjk/
        "It's funny 'cause it's true ... and vice versa."


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

Date: Wed, 29 Apr 1998 21:44:27 -0700
From: "Creede Lambard" <$_=qq!fearless\@NOSPAMio.com!;y/A-Z//d;print>
Subject: Re: You people want Perl to be popular?
Message-Id: <6i8vif$o3a@bgtnsc02.worldnet.att.net>


kpreid@ibm.net (Kevin Reid) wrote:
+ "Creede Lambard" <$_=qq!fearless\@NOSPAMio.com!;y/A-Z//d;print> wrote:
+ > We want Perl to be useful. Popularity ain't all it's cracked up to
be.

+ Being popular helps it be useful, because more people would be writing
+ scripts, modules, etc...

I'm afraid more people writing scripts and modules would mean that there
would be more bad scripts and modules. There's no reason to suppose that
Sturgeon's Law wouldn't apply to the pool of perl programmers. Sad, but
true.





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

Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 8 Mar 97)
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.  

To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.

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.

The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.

The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.

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 V8 Issue 2461
**************************************

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