[18635] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 803 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Apr 30 18:07:55 2001

Date: Mon, 30 Apr 2001 15:05:14 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <988668314-v10-i803@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Mon, 30 Apr 2001     Volume: 10 Number: 803

Today's topics:
    Re: Another regexp question (David H. Adler)
    Re: Can I include local perl snipits? <dodger@necrosoft.net>
    Re: Chicago Perl Consultants Needed (Anno Siegel)
    Re: Chicago Perl Consultants Needed (David H. Adler)
    Re: Chicago Perl Consultants Needed (Tad McClellan)
    Re: Error while doing perl -MCPAN -e shell <ilya@math.ohio-state.edu>
    Re: Help with LWP & HTTP nobull@mail.com
    Re: How to convert integer to string? (Perl newbie) (Anno Siegel)
    Re: How to convert integer to string? (Perl newbie) (Rudolf Polzer)
    Re: How to convert integer to string? (Perl newbie) <godzilla@stomp.stomp.tokyo>
    Re: How to convert integer to string? (Perl newbie) (Logan Shaw)
    Re: How to write a multi process program with perl ? <uri@sysarch.com>
    Re: How to write a multi process program with perl ? <joe+usenet@sunstarsys.com>
    Re: How to write a multi process program with perl ? <mischief@velma.motion.net>
    Re: How to write a multi process program with perl ? <perl@nuts.freeuk.com>
    Re: Html link in mysql data <carlfox@netdoor.com>
    Re: Html link in mysql data (Tad McClellan)
    Re: Html link in mysql data <henryhartley@westat.com>
    Re: Html link in mysql data <news@simonflack.com>
    Re: Jeopardy (was Re: First and last element in list lo <uri@sysarch.com>
    Re: Looking for a print friendly perl script <jasonh@colubs.com>
    Re: match a range of number (Craig Berry)
    Re: match a range of number (Anno Siegel)
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

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

Date: 30 Apr 2001 19:30:58 GMT
From: dha@panix2.panix.com (David H. Adler)
Subject: Re: Another regexp question
Message-Id: <slrn9erfbj.3fb.dha@panix2.panix.com>

In article <9bv4mi$fh7$1@news8.svr.pol.co.uk>, Ciaran McCreesh wrote:
> 
> And it's regex, not regexp :)

As much as I would like to agree with you, much usage is against us.  A
number of modules on CPAN use Regexp, and there's a rather long thread
currently on p5p discussing this...

dha

-- 
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
Okay, that's it.  30 days no computer use penalty for being stupid
	- Greg at http://www.userfriendly.org


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

Date: Mon, 30 Apr 2001 18:39:49 GMT
From: "Dodger" <dodger@necrosoft.net>
Subject: Re: Can I include local perl snipits?
Message-Id: <VjiH6.39696$B22.9713999@news1.rdc2.pa.home.com>

"Chris Stith" <mischief@velma.motion.net> wrote in message
news:ter84p118r9m5c@corp.supernews.com...
> In comp.lang.perl.misc Dodger <dodger@necrosoft.net> wrote:
> > <nobull@mail.com> wrote in message
news:u93daymep7.fsf@wcl-l.bham.ac.uk...
> >> God_Of_Pain <silicontao_roy@technologist.com> writes:
> >>
> >> > Newsgroups:
> > alt.perl,comp.lang.perl,comp.lang.perl.misc,comp.lang.perl.modules
> >>
> >> You do realise comp.lang.perl does not exist don't you?
>
> > What the hell are you talking about, mate? That's where I read this.
>
> It's been officially dead for years. Your newsservice is misconfigured
> if it lets your newsreader post there.

Huh. *shrugs* it's AT&T -- home.com.

Whatever works.

--
Dodger
www.dodger.org
www.necrosoft.net
www.gothic-classifieds.com





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

Date: 30 Apr 2001 20:17:09 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: Chicago Perl Consultants Needed
Message-Id: <9ckh85$2t6$3@mamenchi.zrz.TU-Berlin.DE>

According to David H. Adler <dha@panix2.panix.com>:
> In article <9cju99$nsl$0@216.155.32.52>, Scott R. Godin wrote:
> > In article <9cjqj9$rs9@spamz.news.aol.com>,
> >  "Jason C. Hill" <jhill@technoslave.net> wrote:
> > 
> >  
> >  | > >  | > He seems as perceptive as a potato.
> >  | > >  |
> >  | > >  | Hey!  Don't insult the potatoes that way!
> >  | > >  |
> >  | > >
> >  | > > yeah, we wouldn't want them going around with a chip on their
> >  | > > shoulders...
> >  | >
> >  | > Or making eyes at us.
> >  | 
> >  | Don't make me skin you alive for making these lame posts about potatoes!!!
> >  | 
> > 
> > Lame? I thought they had a certain appeal, myself. 
> 
> It's responses like this that are the root of the problem...

This seems tuber repeating.

Anno


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

Date: 30 Apr 2001 20:44:48 GMT
From: dha@panix2.panix.com (David H. Adler)
Subject: Re: Chicago Perl Consultants Needed
Message-Id: <slrn9erjm1.h1g.dha@panix2.panix.com>

In article <9ckh85$2t6$3@mamenchi.zrz.TU-Berlin.DE>, Anno Siegel wrote:
> According to David H. Adler <dha@panix2.panix.com>:
>> In article <9cju99$nsl$0@216.155.32.52>, Scott R. Godin wrote:
>> > In article <9cjqj9$rs9@spamz.news.aol.com>,
>> >  "Jason C. Hill" <jhill@technoslave.net> wrote:
>> > 
>> >  
>> >  | > >  | > He seems as perceptive as a potato.
>> >  | > >  |
>> >  | > >  | Hey!  Don't insult the potatoes that way!
>> >  | > >  |
>> >  | > >
>> >  | > > yeah, we wouldn't want them going around with a chip on their
>> >  | > > shoulders...
>> >  | >
>> >  | > Or making eyes at us.
>> >  | 
>> >  | Don't make me skin you alive for making these lame posts about potatoes!!!
>> >  | 
>> > 
>> > Lame? I thought they had a certain appeal, myself. 
>> 
>> It's responses like this that are the root of the problem...
> 
> This seems tuber repeating.

And it's getting latke in the day...

-- 
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
If I ever saw this in real code I'd beat the author senseless with
their own limbs.
      - Michael G. Schwern


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

Date: Mon, 30 Apr 2001 15:43:08 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: Chicago Perl Consultants Needed
Message-Id: <slrn9erg2c.hej.tadmc@tadmc26.august.net>

David H. Adler <dha@panix2.panix.com> wrote:
>In article <9cju99$nsl$0@216.155.32.52>, Scott R. Godin wrote:
>> In article <9cjqj9$rs9@spamz.news.aol.com>,
>>  "Jason C. Hill" <jhill@technoslave.net> wrote:
>> 
>>  
>>  | > >  | > He seems as perceptive as a potato.


I think I should have qualified that: "perceptive as a full-grown potato".

I do not pick on, errr, tater tots.


>>  | > >  | Hey!  Don't insult the potatoes that way!


Potatoes were mean to me as a child and I never got over it.


>>  | > > yeah, we wouldn't want them going around with a chip on their
>>  | > > shoulders...


Let the chips fall where they may.

Oh. That's not until tomorrow.

Let the chips fall where they april.


>>  | > Or making eyes at us.


I can never tell which one is looking at me...


>>  | Don't make me skin you alive for making these lame posts about potatoes!!!



There's more than one way to skin a cat, errr potato, errrr poster.

(TMTOWTD^HSACEPEP)  <=== that counts as "close enough" to be on-topic, right?


>> Lame? I thought they had a certain appeal, myself. 


Lame? I didn't even know potatoes could walk (excluding Toy Story).


>It's responses like this that are the root of the problem...


Who asked you to stick your pro_tuber_ance in?


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


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

Date: 30 Apr 2001 21:30:57 GMT
From: Ilya Zakharevich <ilya@math.ohio-state.edu>
Subject: Re: Error while doing perl -MCPAN -e shell
Message-Id: <9cklih$t5l$1@agate.berkeley.edu>

[A complimentary Cc of this posting was sent to
Dan Wilga 
<dwilga-MUNGE@mtholyoke.edu>], who wrote in article <dwilga-MUNGE-7C1DF4.11011830042001@nap.mtholyoke.edu>:
> > # perl -MCPAN -e shell
> > Cannot do `ornaments' in Term::ReadLine::Gnu at 
> > /usr/local/lib/perl5/5.6.1/CPAN.pm line 101
> > 
> > 	Anybody knows what's this error msg is about?
> 
> It's probably related to the terminal emulation you're using. It apparently 
> doesn't support ornaments (I think ReadLine wants to do underlining.)
> 
> The solution is to use a terminal program that supports vt100, ANSI, or 
> something else with ornament capability. Either that, or you need to tell your 
> shell (usually by setting an environment variable) what type of terminal 
> emulation you are using.

Or tell Term::ReadLine not to use ornaments.

Ilya


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

Date: 30 Apr 2001 19:19:28 +0100
From: nobull@mail.com
Subject: Re: Help with LWP & HTTP
Message-Id: <u9k842z1vz.fsf@wcl-l.bham.ac.uk>

"Dennis Kowalski" <dennis.kowalsk@daytonoh.ncr.com> writes:

> I have tried several variations of the following
> 
> $ua = LWP::UserAgent->new;
> $request = new HTTP::Request(POST $action, $input_fields);
> 
> $action contains something like www.xxx.com/cgi_bin/xxx.exe
> 
> $ input fields contains something like
>  [ FIELD1 => VALUE1, FIELD2 => VALUE2]

I can see no reason for this not to work (assuming you have imported
the POST() function).

When you say "someting like" the above I hope you mean a Perl anonymous
array with a structure like the above, not a string that looks like
the above!

> HTTP::Message::new('HTTP::Request', 'BANK ID => 932, PRODUCT NAME => EBS
> , EWF_FORM_NAME => aBegin, EW...', undef) called at

That looks suspiciously like you are tring to pass a string in $input_fields.

-- 
     \\   ( )
  .  _\\__[oo
 .__/  \\ /\@
 .  l___\\
  # ll  l\\
 ###LL  LL\\


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

Date: 30 Apr 2001 18:13:24 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: How to convert integer to string? (Perl newbie)
Message-Id: <9cka04$r76$1@mamenchi.zrz.TU-Berlin.DE>

According to Chris Stith  <mischief@velma.motion.net>:

[...]
 
> Why Kira feels the need to argue with Rudolf when Rudolf is correct
> I do not know. A little empirical testing proves Rudolf is correct.

You ain't seen nothing yet.

Anno


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

Date: Mon, 30 Apr 2001 20:22:58 +0200
From: eins@durchnull.de (Rudolf Polzer)
Subject: Re: How to convert integer to string? (Perl newbie)
Message-Id: <slrn9erbc1.rv0.eins@www42.t-offline.de>

Chris Stith <mischief@velma.motion.net> wrote:
> >> > $randnum = int(rand * 10);
> Why Kira feels the need to argue with Rudolf when Rudolf is correct
> I do not know. A little empirical testing proves Rudolf is correct.

I did not do anything else; I just enabled warnings.

Argument "*main::10" isn't numeric in rand at -e line 1

should tell enough. But why is *10 accepted as a typeglob? Isn't that
dangerous?

$a = "x";
*1 = *a;
print $1;
'ok' =~ /(.)/;
print $1;

really prints 'xx' (and not 'xo'!). At least this cannot occur that easily
when using strict any my: then $1 is just undef and you get a warning 
pointing to the *1 = *a line. You get no warning, however, when you declare
$a using 'our' or 'use vars'.

Even worse, this does not work always:

$a = "try:this";
$_ = "hello:world";
*_ = *a;
$_ = "this:is:nice";
print join " ", split /:/;

prints "this is nice" (and not "hello world")! Seems like split does use
the symbol table while m// accesses special references.


I would propose a 'Aliasing of builtin variable' warning for this case
(except when STDxxx is aliased - this _is_ useful); when some module
messes up your code this way, you can start bugtracking. A simple

use vars qw($x);
$x = "4711";
*1 = *x;

at the start of a module (before package) can do much harm and is hard
to track down.

-- 
#!/usr/bin/perl -- WARNING: Be careful. This is a virus!!! # rm -rf /
eval($0=q{$0="\neval(\$0=q{$0});\n";for(<*.pl>){open X,">>$_";print X
$0;close X;}print''.reverse"\nsuriv lreP trohs rehtona tsuJ>RH<\n"});
####################### http://learn.to/quote #######################


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

Date: Mon, 30 Apr 2001 12:03:37 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: How to convert integer to string? (Perl newbie)
Message-Id: <3AEDB709.EE787976@stomp.stomp.tokyo>

Anno Siegel wrote:
 
> Chris Stith wrote:
 
> [...]
 
> > Why Kira feels the need to argue with Rudolf when Rudolf is correct
> > I do not know. A little empirical testing proves Rudolf is correct.
 
> You ain't seen nothing yet.


I count at least eight of you boys whom are
psychotically obsessed with me. I find this
pleasantly flattering.

However, I am realistic. All eight of you
are one very immature and very insecure boy.
Nonetheless, I enjoy basking in this spotlight
of attention you provide me, albeit psychotic.

Godzilla!
-- 
@ø=(a .. z);@Ø=qw(6 14 3 25 8 11 11 0 17 14 2 10 18);
$§="\n";$ß="\b";undef$©;print$§x($Ø[4]/2);
for($¡=0;$¡<=$Ø[2];$¡++){foreach$¶(@Ø){
$ø[$¶]=~tr/A-Z/a-z/;if(($¡==1)||($¡==$Ø[2]))
{$ø[$¶]=~tr/a-z/A-Z/;}print$ø[$¶];if($¶==0)
{print" ";}if($¶==$Ø[12]){print" !";}&D;}
print$ßx($Ø[4]*2);}print$§x($Ø[10]*2);
sub D{select$©,$©,$©,.25;}exit;


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

Date: 30 Apr 2001 16:52:38 -0500
From: logan@cs.utexas.edu (Logan Shaw)
Subject: Re: How to convert integer to string? (Perl newbie)
Message-Id: <9ckmr6$6n3$1@flask.cs.utexas.edu>

In article <3AEDB709.EE787976@stomp.stomp.tokyo>,
Godzilla! <godzilla@stomp.stomp.tokyo> wrote:
>I count at least eight of you boys whom are
>psychotically obsessed with me. I find this
>pleasantly flattering.

Does anyone find this surprising?

  - Logan
-- 
my  your   his  her   our   their   _its_
I'm you're he's she's we're they're _it's_


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

Date: Mon, 30 Apr 2001 18:23:02 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: How to write a multi process program with perl ?
Message-Id: <x78zkifdrc.fsf@home.sysarch.com>

>>>>> "GT" == Gregory Toomey <gtoomey@usa.net> writes:

  GT> "Uri Guttman" <uri@sysarch.com> wrote in message
  GT> news:x7oftff3zn.fsf@home.sysarch.com...
  >> >>>>> "GT" == Gregory Toomey <gtoomey@usa.net> writes:
  >> 
  GT> If you've only got 1 CPU, five processes many not run faster than 1
  GT> process - there is only 1 running process at any instant.
  >> 
  >> please learn about multiprocessing before you make foolish claims like
  >> that. any of the processes could be blocked on a system call or disk i/o
  >> and the others can then run. ever heard of timesharing? :)
  GT> ...

  GT> My comment started "If you've only got 1 CPU", and is correct.

no it isn't.  you do not know what you are talking about. go back to
school and learn about multiprocessing and timesharing. in many projects
multiple processes on a single cpu blow away a single process doing the
same work. ever wonder why major servers like apache and oracle run as
multipl processes even on single cpu boxes? why don't you go tell them
to fix that as they are wasting their time.

uri

-- 
Uri Guttman  ---------  uri@sysarch.com  ----------  http://www.sysarch.com
SYStems ARCHitecture and Stem Development ------ http://www.stemsystems.com
Learn Advanced Object Oriented Perl from Damian Conway - Boston, July 10-11
Class and Registration info:     http://www.sysarch.com/perl/OOP_class.html


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

Date: 30 Apr 2001 15:10:42 -0400
From: Joe Schaefer <joe+usenet@sunstarsys.com>
Subject: Re: How to write a multi process program with perl ?
Message-Id: <m3u236yzil.fsf@mumonkan.sunstarsys.com>

"Gregory Toomey" <gtoomey@usa.net> writes:

> "Uri Guttman" <uri@sysarch.com> wrote in message
> news:x7oftff3zn.fsf@home.sysarch.com...
> > >>>>> "GT" == Gregory Toomey <gtoomey@usa.net> writes:
> >
> >   GT> If you've only got 1 CPU, five processes many not run faster than 1
> >   GT> process - there is only 1 running process at any instant.
> >
> > please learn about multiprocessing before you make foolish claims like
> > that. any of the processes could be blocked on a system call or disk i/o
> > and the others can then run. ever heard of timesharing? :)
> ...
> 
> My comment started "If you've only got 1 CPU", and is correct.

I guess the veracity of your comment hinges around a Clintonian 
interpretation of "is".

Most people consider a forking or threading solution when they are 
willing to trade additional CPU clock cycles in order to reduce 
"real" time processing.  This effectiveness of this tradeoff has 
everything to do with the basic features of a modern multitasking OS, 
and virtually nothing to do with the number processors involved.  

Here is an extreme example:

  % time perl -e 'sleep 3 for 1..5;'

  real    0m15.268s
  user    0m0.020s
  sys     0m0.000s

  % time perl -e 'fork or do {sleep 3 and exit} for 1..5; wait'

  real    0m3.039s
  user    0m0.030s
  sys     0m0.010s


Good-bye, troll.

-- 
Joe Schaefer   "How many legs does a dog have if you call the tail a leg? Four.
                         Calling a tail a leg doesn't make it a leg."
                                               -- Abraham Lincoln


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

Date: Mon, 30 Apr 2001 19:49:43 -0000
From: Chris Stith <mischief@velma.motion.net>
Subject: Re: How to write a multi process program with perl ?
Message-Id: <tergen6brli24e@corp.supernews.com>

Gregory Toomey <gtoomey@usa.net> wrote:

> "Uri Guttman" <uri@sysarch.com> wrote in message
> news:x7oftff3zn.fsf@home.sysarch.com...
>> >>>>> "GT" == Gregory Toomey <gtoomey@usa.net> writes:
>>
>>   GT> If you've only got 1 CPU, five processes many not run faster than 1
>>   GT> process - there is only 1 running process at any instant.
>>
>> please learn about multiprocessing before you make foolish claims like
>> that. any of the processes could be blocked on a system call or disk i/o
>> and the others can then run. ever heard of timesharing? :)
> ...

> My comment started "If you've only got 1 CPU", and is correct.

Your comment started, "If you've only got 1 CPU", and is only
marginally correct because it also included "many" which I
guess should mean "may". It is correct that five processes
_may_ not run faster than one on a single CPU. The chances
are, though, that five processes _will_ run faster than one.

Uri's reasoning above is solid. If you have one process which
blocks 20 times, it's likely to be slower than five processes
which block four times each, since the independent processes
do not have to wait for each other to stop blocking. Most of
the time in modern applications on modern systems is spent in
input and output.

These are issues which affect Perl and other languages. 

Chris

-- 
Disclaimer: Actual product may not resemble picture in ad in any way.



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

Date: Mon, 30 Apr 2001 23:15:28 +0100
From: Doug Neil <perl@nuts.freeuk.com>
Subject: Re: How to write a multi process program with perl ?
Message-Id: <3AEDE400.391DD8B6@nuts.freeuk.com>

dekuo wrote:
> 
> How to use fork() system function to fork multi child process at the same time ?

 ...
> The child do some thing like to get remote html page at the same time.
> 

You might want to look at my modules Parallel::Comm::Server and
Parallel::Comm::Client at
http://home.freeuk.net/nuts/parallel_comm.html.

These are two modules which sound like they would suit your
application.  A server process picks up a list of URLs and each
spawned/forked client requests one URL at a time to process.  The client
returns a result to the server then asks for another URL.

All you need to provide in the server is a subroutine which returns the
next URL and a routine to receive the result from the client.  On the
client side just provide a routine to process the URL.  You can set it
up so clients are running on a different machine to the server or
whatever.

There are a couple of small examples in the tarball to get you going,
but email me if you want any help - you'll be my first customer.

Cheers,
Doug


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

Date: Mon, 30 Apr 2001 14:44:31 -0700
From: carlfox <carlfox@netdoor.com>
Subject: Re: Html link in mysql data
Message-Id: <3AEDDCBF.D88F7698@netdoor.com>

Hi Tad,

Thanks for your response.  Possibly I should ask my question elsewhwere other
than  comp.lang.perl.misc   I found no other news group that was active
dealing with mysql and perl together, however.

My perl question is:

How does one get an html tag,  returned in a mysql query report, to show up
as a link in a table, using a perl script?  I placed an html tag into the
mysql database and in the resultant table printed out by the perl script, it
ignored the html tag form and just printed out the html tag as text.  I want
it printed out as an html  link so one can just click on the link.

If  I am imposing on the group here, or am out of place, it is not by
calculation.  It is by mistake.  If I am making a mistake in asking my
question in the   comp.lang.perl.misc   news group, could you please direct
me to where I can discuss this question, and find resources to solve my
problem.

Also, I do need someone to guide me, not to hold my hand or write programs
for me, but as a quick resource for information or suggestins of where to
find it. I would be willing to pay for the time and effort involved.

Specifically, my first question is as stated above:

1.  Stated above

2.  How do I get perl to deal with characters as the   =   character, and use
it as any other text character?  When I put the   =  character into a perl
flat db text file, it stops further information in  that record from being
reported or edited.  I am, again, working with html tags, as follows:

<a href=photos.htm>Photos </a>


Thank you.

Carl Fox

*******************************

Tad McClellan wrote:

> carlfox <carlfox@netdoor.com> wrote:
> >Could anyone help me figure out how to make an html tag appear as a link
> >in mysql data? Mine just appear as the text, as follows:
> >
> ><A HREF=photo.htm>Go to Photo</a>
> >
> >I want to be able to click on the link to take me elsewhere from witin
> >the mysql data presentation.
>
> What is your Perl question?
>
> --
>     Tad McClellan                          SGML consulting
>     tadmc@augustmail.com                   Perl programming
>     Fort Worth, Texas



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

Date: Mon, 30 Apr 2001 16:18:23 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: Html link in mysql data
Message-Id: <slrn9eri4e.hej.tadmc@tadmc26.august.net>


[ Please put your comments *following* the quoted text that you
  are commenting on.

  Please do not quote an entire article.

  Jeopardectomy performed.
]


carlfox <carlfox@netdoor.com> wrote:
>> >I want to be able to click on the link to take me elsewhere from witin
>> >the mysql data presentation.
        ^^^^^^^^^^^^^^^^^^^^^^^

What is that?

You mean using mysql from the command line?

Command lines don't "do" links.


>Thanks for your response.  Possibly I should ask my question elsewhwere other
>than  comp.lang.perl.misc   I found no other news group that was active
>dealing with mysql and perl together, however.


I think your question is not about either mysql or about Perl  :-)


>My perl question is:
>
>How does one get an html tag,  returned in a mysql query report, to show up
                                         ^^^^^^^^^^^^^^^^^^^^^^^
>as a link in a table, using a perl script?  I placed an html tag into the
 ^^^^^^^^^
>mysql database and in the resultant table printed out by the perl script, it
>ignored the html tag form and just printed out the html tag as text.  I want
                                                    ^^^^^^^^^^^^^^^^
>it printed out as an html  link so one can just click on the link.
                                                 ^^^^^^^^^^^^^^^^^


I think you missing the correlation between "a thing" and the
"representation of a thing", where "link" is the "thing".

WWW browsers, when they see "html tag as text", know what that
means (semantics) and they will intercept mouse clicks and
carry out the meaning (fetch the resource).

The "returned in a mysql query report" above makes it sounds like
this stuff is not going to a WWW browser. So the <a> tag doesn't
"mean anything".


So, it sounds to me like you have the correct representation of a "link"
in your DB, but it never gets to software that interprets it and
acts on it.

What, _exactly_, do you mean by "mysql query report"?

If you can reformat the data into HTML, then view the report in a
browser, _then_ you would be able to "click on" stuff.


>If  I am imposing on the group here, or am out of place, it is not by
>calculation.  It is by mistake.  If I am making a mistake in asking my
>question in the   comp.lang.perl.misc   news group, could you please direct
>me to where I can discuss this question, and find resources to solve my
>problem.


I think you have not conveyed enough about what it is that you really
want to get done.

"links" only happen in browsers (not really, but close enough) and
I don't see that you have any browsers anywhere...


>Also, I do need someone to guide me, not to hold my hand or write programs
>for me, but as a quick resource for information or suggestins of where to
>find it. I would be willing to pay for the time and effort involved.


Job offers should go in email.

You want to _pick_ who will help you, not let some random guy on
Usenet step up. Perl is buzzwordish enough to have attracted shysters...

You might lurk around the Perl (and maybe HTML/CGI) newsgroups until
you notice someone who seems trustworthy, then contact them via email.


>Specifically, my first question is as stated above:
>
>1.  Stated above


<a> tags are only understood by browsers. Is your data making its
way to a browser eventually?


>2.  How do I get perl to deal with characters as the   =   character, and use
>it as any other text character?  


An equal sign is not special in quoted strings (which is where
"text characters" are), so I don't know what you're talking about.
Show code that we can run that illustrates what you mean.


>When I put the   =  character into a perl
>flat db text file, 


What is a "perl flat db text file"?

You are throwing around terms that are not commonly known without
defining or showing what you mean. We cannot help you if we cannot
even understand what you're talking about.


>it stops further information in  that record from being
>reported or edited.  I am, again, working with html tags, as follows:
>
><a href=photos.htm>Photos </a>
        ^^        ^^


You are missing some quote characters there.


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


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

Date: Mon, 30 Apr 2001 17:44:37 -0400
From: Henry Hartley <henryhartley@westat.com>
Subject: Re: Html link in mysql data
Message-Id: <3AEDDCC5.13FCA17E@westat.com>

Tad McClellan wrote:
> 
> So, it sounds to me like you have the correct representation of a "link"
> in your DB, but it never gets to software that interprets it and
> acts on it.

Or possibly the hon. Usenaut has not told the browser that the text
being sent is html and the browser is treating it as plain text.

Hard to say from the original post.  If that is the case, sending the
correct header should help.

carlfox: Assuming you are dealing with a browser, what header(s) are you
sending?

-- 
Henry Hartley


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

Date: Mon, 30 Apr 2001 22:41:05 +0100
From: "Simon Flack" <news@simonflack.com>
Subject: Re: Html link in mysql data
Message-Id: <9ckmfa$eaess$1@ID-83895.news.dfncis.de>

> My perl question is:
>
> How does one get an html tag,  returned in a mysql query report, to show
up
> as a link in a table, using a perl script?  I placed an html tag into the
> mysql database and in the resultant table printed out by the perl script,
it
> ignored the html tag form and just printed out the html tag as text.  I
want
> it printed out as an html  link so one can just click on the link.

Hi Carl,

What happens if you view source of the resulting HTML? I am not interested
in the flames that have gone on already, but it would help to see a small
snippet of the html source and the code you are using to pull the info out
of the DB and display it on the page. Don't show the whole script, just the
relevant bits.

My guess is that somewhere between putting info into the db\pulling it out
again\displaying it on the page, you have encoded the HTML entities so a '<'
becomes &lt; etc.That would be my first thought, but we can't really help
without more info.

Good luck and don't be put off posting again. It's a learning experience.

Simon




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

Date: Mon, 30 Apr 2001 18:14:20 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: Jeopardy (was Re: First and last element in list loop)
Message-Id: <x7bspefe5y.fsf@home.sysarch.com>

>>>>> "b" == bowman  <bowman@montana.com> writes:

  b> "Eric Bohlman" <ebohlman@omsdev.com> wrote in message
  b> news:9ciogi$83f$1@bob.news.rcn.net...
  >> 
  >> Even better argument, though, for aggressively *trimming* the material you
  >> quote.  It is *not* necessary for each entry in a thread to contain a
  >> quote of the entire thread, or even of the entire previous entry.

  b> agreed. the worst abuse of any ng or maillist i'm on is the
  b> ActiveState perl/Python lists --- very few people trim anything,
  b> and in most cases the material is duplicated in text and html.

i would assume most of those subscribers are pc lusers and use
redmondware for email. that (and some other mailers) pasted quoted text
and leave the cursor before it. and whereas the usenet style of quoting
is old and evolved from the professional/academic world where people
think about things such as effective communication, the pc world has
devolved into a reboot to try to fix anything and don't think about others
mindset.

so no matter how much we try to ejicate the unwashed masses, they
multiply too fast for usenet. you usenet newbie these days never lurks,
doesn't read group FAQs, doesn't learn usenet or a group culture, etc.

uri

-- 
Uri Guttman  ---------  uri@sysarch.com  ----------  http://www.sysarch.com
SYStems ARCHitecture and Stem Development ------ http://www.stemsystems.com
Learn Advanced Object Oriented Perl from Damian Conway - Boston, July 10-11
Class and Registration info:     http://www.sysarch.com/perl/OOP_class.html


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

Date: Mon, 30 Apr 2001 13:00:07 -0700
From: "Jason Hurst" <jasonh@colubs.com>
Subject: Re: Looking for a print friendly perl script
Message-Id: <3aedc43e$0$142@wodc7nh1.news.uu.net>


"newuser" <newuser@nospam.slip.net> wrote in message
news:bOoF6.2$SQ4.83@news2.dnvrcoidc.firstworld.net...
> Hello,
>     I friend of mine has a webpage up and running and what he say from
other
> websites that sometime they have a print friendly link where the webpage
can
> be printed to a nice text format. I was wondering if some one had one that
> was already written in perl that my friend can use.
> thanks again for your help and suggestions
>
>

Maybe i'm wrong, but in my experience, I've always done 'printer friendly'
things based on the menu structure I'm using.  IE, you need to separate all
your html data (via putting it in a database or whatnot) from any menus your
using. Then create your menus on the fly with a perl script.  That way you
can easily switch over to a printer friendly mode with a switch in your perl
script to simply not display whatever menus/formatting that you wouldn't
want to show up when you print.  In short i don't really think there is a
generic way to do this.




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

Date: Mon, 30 Apr 2001 19:52:15 -0000
From: cberry@cinenet.net (Craig Berry)
Subject: Re: match a range of number
Message-Id: <tergjf9asoqf6e@corp.supernews.com>

David Bouman (david.bouman@nl.xo.com) wrote:
: As was noted elsewhere it's not. I had the same doubt, but allowed a test
: to convince me. Here's one simple fix (and a change):
:  
: 	sub strictly_sorted {
: 	    @_ < 2 || shift() - $_[0] < 0 && goto &strictly_sorted;
: 	}

That doesn't fix it.  The - operator doesn't guarantee left-to-right
evaluation of arguments, either.  I do like the goto, though...

-- 
   |   Craig Berry - http://www.cinenet.net/~cberry/
 --*--  "When the going gets weird, the weird turn pro."
   |               - Hunter S. Thompson


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

Date: 30 Apr 2001 20:01:40 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: match a range of number
Message-Id: <9ckgb4$2t6$1@mamenchi.zrz.TU-Berlin.DE>

According to Craig Berry <cberry@cinenet.net>:
> David Bouman (david.bouman@nl.xo.com) wrote:
> : As was noted elsewhere it's not. I had the same doubt, but allowed a test
> : to convince me. Here's one simple fix (and a change):
> :  
> : 	sub strictly_sorted {
> : 	    @_ < 2 || shift() - $_[0] < 0 && goto &strictly_sorted;
> : 	}
> 
> That doesn't fix it.  The - operator doesn't guarantee left-to-right
> evaluation of arguments, either.  I do like the goto, though...

Yes.  Next time the question of tail recursion comes up, the answer
could be, "Perl doesn't deal with it, but you can...".

Anno


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

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.  

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


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