Re: Can't locate HTML::Parser in @INC

2009-06-05 Thread Peter Nikolaidis
>> Any suggestions? > > What about file permissions? Does the user the test script was run as > have read access to > /usr/local/lib/perl5/site_perl/5.10.0/x86_64-linux/HTML/Parser.pm ? Hello, I just tried running the test script as root and got the same results, so I do not think it is a permis

Re: Can't locate HTML::Parser in @INC

2009-06-04 Thread Gunnar Hjalmarsson
Peter Nikolaidis wrote: I wrote a test script, which does nothing more than require HTML::Parser, and it fails with the following: catu...@www2:~$ perl test.plx Can't locate HTML::Parser in @INC (@INC contains: /usr/local/lib/perl5/5.10.0/x86_64-linux /usr/local/lib/perl5/5.10.0 /usr/

Can't locate HTML::Parser in @INC

2009-06-04 Thread Peter Nikolaidis
Hello, We're running a Debian 5 (AMD64) server, with Perl 5.10 compiled from source because we require a non-threaded Perl for an e-commerce app. It fails to load, complaining that several modules were not found, including, for instance, HTML::Parser. I installed this via /usr/local/bin

Re: scalar / hash problem in HTML::Parser

2008-02-25 Thread Tim Bowden
I need to find a way to get HTML::Parser return the text between the tag caught by the start_h handler and the related closing tag. Could someone please point me in the right direction? Cut down code thus far: #!/usr/bin/perl -wT use strict; use HTML::Parser; my %choices; my $file

Re: scalar / hash problem in HTML::Parser

2008-02-25 Thread Tim Bowden
Thanks Chas, most useful. Regards, Tim Bowden On Mon, 2008-02-25 at 09:55 -0500, Chas. Owens wrote: > On Mon, Feb 25, 2008 at 9:01 AM, Tim Bowden <[EMAIL PROTECTED]> wrote: > > Making progress. Needed to understand hash references, and how to > > de-reference them. > snip > > Quick cheat sheet:

Re: scalar / hash problem in HTML::Parser

2008-02-25 Thread MK
On Mon, 2008-02-25 at 14:54 +0900, Tim Bowden wrote: -> > Hi all, -> > -> > I'm using HTML::Parser to process files containing snippets of html -> > looking like: -> > First optionAnother -> > choicepick me -> > -> > I'm wanting to create a hash

Re: scalar / hash problem in HTML::Parser

2008-02-25 Thread Chas. Owens
On Mon, Feb 25, 2008 at 9:01 AM, Tim Bowden <[EMAIL PROTECTED]> wrote: > Making progress. Needed to understand hash references, and how to > de-reference them. snip Quick cheat sheet: #make a hash reference my $ref = \%hash; my $ref = { key1 => "val1", key2 => "val2" }; my $ref = { %hash }; #

Re: scalar / hash problem in HTML::Parser

2008-02-25 Thread Tim Bowden
Making progress. Needed to understand hash references, and how to de-reference them. Tim Bowden On Mon, 2008-02-25 at 14:54 +0900, Tim Bowden wrote: > Hi all, > > I'm using HTML::Parser to process files containing snippets of html > looking like: > First optionAnother >

scalar / hash problem in HTML::Parser

2008-02-24 Thread Tim Bowden
Hi all, I'm using HTML::Parser to process files containing snippets of html looking like: First optionAnother choicepick me I'm wanting to create a hash of option value, name pairs. Ie, 1 => "First option",2=>"Another choice" and so on. Problem is, I don&#x

Re: HTML::Parser does give any result of its "sub text{...}".

2007-10-16 Thread Patrik Hasibuan
> wrote: > > > Please tell me my mistake. > > I'll catch enough to give you something to do, and leave the rest for > you and others to find. :-) > > > use HTML::Parser; > > It looks as if you're not subclassing HTML::Parser. Isn't that > ob

Re: HTML::Parser does give any result of its "sub text{...}".

2007-10-16 Thread Patrik Hasibuan
with "LWP::UserAgent". For the > > parsing I use "HTML::Parser". > > But the parsing process does not give any result. I still do not understand > > the documentation those I get from > > - http://www.foo.be/docs/tpj/issues/vol5_1/tpj0501-0003.html ; >

Re: HTML::Parser does give any result of its "sub text{...}".

2007-10-12 Thread Tom Phoenix
On 10/12/07, Patrik Hasibuan <[EMAIL PROTECTED]> wrote: > Please tell me my mistake. I'll catch enough to give you something to do, and leave the rest for you and others to find. :-) > use HTML::Parser; It looks as if you're not subclassing HTML::Parser. Isn't tha

Re: HTML::Parser does give any result of its "sub text{...}".

2007-10-12 Thread Patrik Hasibuan
Dear Jenda and friends... I modified the code but the result is still empty. Please tell me my mistake. === Here is my current code: #!/usr/bin/perl -w use strict; use LWP::UserAgent; use HTML::Parser; my @result=''; my @judul=''; my @bodi=''; my $tekshslparse=

Re: HTML::Parser does give any result of its "sub text{...}".

2007-10-12 Thread Jenda Krynicky
From: Patrik Hasibuan <[EMAIL PROTECTED]> > I want to parse HTML files those I retrieve with "LWP::UserAgent". For the > parsing I use "HTML::Parser". > But the parsing process does not give any result. I still do not understand > the d

HTML::Parser does give any result of its "sub text{...}".

2007-10-12 Thread Patrik Hasibuan
Dear my friends... I want to parse HTML files those I retrieve with "LWP::UserAgent". For the parsing I use "HTML::Parser". But the parsing process does not give any result. I still do not understand the documentation those I get from - http://www.foo.be/docs/tpj/issues/vol5

Re: Howto strip html from a $calar with HTML::Parser

2007-08-03 Thread Alan C
Thanks for the replies. I've added them to my searchable data. My forgetfullness worsens as I get older. I'd totally forgotten that I'd once done this with HTML::Strip And I began reinventing the wheel the other day. Lynx too, forgot about that (Slackware 12.0 right now). Anyways, here's a mo

Re: Howto strip html from a $calar with HTML::Parser

2007-08-03 Thread Mumia W.
On 08/03/2007 03:30 AM, Alan C wrote: [...] I do not need to print to STDOUT Is the print @ line in the sub doing this? [...] Yes. Why not append the text to $string instead of printing the text? -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

Howto strip html from a $calar with HTML::Parser

2007-08-03 Thread Alan C
Hi, I saw the doc for HTML::Parser. I looked at its hstrip program in the eg folder but dunno how to strip a scalar instead of a file. I can strip a file. But I want to strip a scalar. Any help appreciated. As my code is currently, when ran, it prints text to STDOUT and the $source scalar

Re: Regex...HTML::Parser...Getting webpage data?

2006-08-05 Thread Rob Dixon
Wesley Bresson wrote: > > Thanks for your example script using HTML::Treebuilder, however I'm > trying to figure out why it appears to grab some items but not others. > I've removed the $20-100 limitation (I didn't need it, I really just > need to poll one item) but am still missing some of the it

Re: Regex...HTML::Parser...Getting webpage data?

2006-08-05 Thread Mumia W.
On 08/04/2006 02:25 PM, Wesley Bresson wrote: Thanks for your example script using HTML::Treebuilder, however I'm trying to figure out why it appears to grab some items but not others. [...] What appears to grab some items but not others? You didn't show anyone your program, so how can they

Re: Regex...HTML::Parser...Getting webpage data?

2006-08-05 Thread Wesley Bresson
... Two Web questions in one day! It's hard to know exactly how you're going to your code Wesley, but the stuff below should be a good starter. It pulls in the web site and parses it using HTML::TreeBuilder. It looks for all table row elements that contain exactly five table data elements, wh

Re: Regex...HTML::Parser...Getting webpage data?

2006-08-04 Thread Mumia W.
I am trying to retrieve data from a webpage, say http://www.apmex.com/shop/buy/Silver_American_Eagles.asp?orderid=0 for example, the price of a 2006 1oz Silver American Eagle in the 20-99 price break quantity. Should I use Regex to do that or would I be better off with HTML::Parser ? I've attemped R

Re: Regex...HTML::Parser...Getting webpage data?

2006-08-04 Thread Rob Dixon
am trying to retrieve data from a webpage, say > http://www.apmex.com/shop/buy/Silver_American_Eagles.asp?orderid=0 for > example, the price of a 2006 1oz Silver American Eagle in the 20-99 price > break quantity. Should I use Regex to do that or would I be better off with > HTML:

Regex...HTML::Parser...Getting webpage data?

2006-08-04 Thread Wesley Bresson
//www.apmex.com/shop/buy/Silver_American_Eagles.asp?orderid=0 for example, the price of a 2006 1oz Silver American Eagle in the 20-99 price break quantity. Should I use Regex to do that or would I be better off with HTML::Parser ? I've attemped Regex since I seem to understand it better but have

FW: Wanted: Help selecting XPath/XMLDom/HTML parser

2006-04-08 Thread Siegfried Heintze
Let me try this again now that I am subscribed to the list! -Original Message- From: Siegfried Heintze [mailto:[EMAIL PROTECTED] Sent: Saturday, April 08, 2006 12:03 PM To: 'Perl Beginners' Subject: Wanted: Help selecting XPath/XMLDom/HTML parser Which module will load raw H

Wanted: Help selecting XPath/XMLDom/HTML parser

2006-04-08 Thread Siegfried Heintze
Which module will load raw HTML into a XMLDom so I can query it with Xpath? I can find HTML parsers and XML parsers but I'm having trouble finding an HTML DOM (not SAX) parser that accepts Xpath queries. Thanks, Siegfried -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-

HTML::Parser Tutorial

2005-11-29 Thread Mandar Rahurkar
Hi, Is anyone familiar with a doos tutorial on HTML::Parser module ? Thanks, Mandar -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>

Re: How to add my own start method to existing HTML::Parser class to Scrape Screens?

2005-04-25 Thread Wiggins d'Anconia
Siegfried Heintze wrote: > I'm trying to screen scape some information off the web. > > I anticipate that I'll want to have it multi-threaded. > > As per Lincoln Stein's book, I'm using HTML::Parser and passing a function > pointer (you can tell I'

How to add my own start method to existing HTML::Parser class to Scrape Screens?

2005-04-22 Thread Siegfried Heintze
I'm trying to screen scape some information off the web. I anticipate that I'll want to have it multi-threaded. As per Lincoln Stein's book, I'm using HTML::Parser and passing a function pointer (you can tell I'm a C programmer) to $parser->handler(start=> \&

Re: subclassing HTML::Parser

2004-08-01 Thread Andrew Gaffney
Charles K. Clarkson wrote: From: Andrew Gaffney <mailto:[EMAIL PROTECTED]> wrote: : I've created a module that uses HTML::Parser to parse some : HTML and create a tree structure. Someone had suggested to : use HTML::TreeBuilder, but my HTML contains HTML::Mason : code embedde

RE: subclassing HTML::Parser

2004-08-01 Thread Charles K. Clarkson
From: Andrew Gaffney <mailto:[EMAIL PROTECTED]> wrote: : I've created a module that uses HTML::Parser to parse some : HTML and create a tree structure. Someone had suggested to : use HTML::TreeBuilder, but my HTML contains HTML::Mason : code embedded, and HTML::TreeBuilder doesn&#x

subclassing HTML::Parser

2004-07-29 Thread Andrew Gaffney
I've created a module that uses HTML::Parser to parse some HTML and create a tree structure. Someone had suggested to use HTML::TreeBuilder, but my HTML contains HTML::Mason code embedded, and HTML::TreeBuilder doesn't handle that well at all. HTML::TreeBuilder also adds , , and

Re: print output from HTML::Parser

2003-03-08 Thread Scott R. Godin
Steven Massey wrote: > Hi all > > perl script below works, and does what I hoped it would, but I don't seem > to understand how to get it to print out the result to a new file as > opposed to stdout. > > Thanks for any help > > #!/usr/bin/perl -w > use strict

RE: print output from HTML::Parser

2003-03-07 Thread wiggins
t; opposed to stdout. > > Thanks for any help > > #!/usr/bin/perl -w > use strict; > use HTML::Parser; > > open(OUT, ">/share/file1") || die "Cannot open /share/file1: $!\n"; > > my $html = HTML::Parser->new( >

RE: print output from HTML::Parser

2003-03-07 Thread Dan Muey
> Hi all > > perl script below works, and does what I hoped it would, but > I don't seem to understand how to get it to print out the > result to a new file as opposed to stdout. > > Thanks for any help > > #!/usr/bin/perl -w > use strict; > use HTML:

RE: print output from HTML::Parser

2003-03-07 Thread Hanson, Rob
. Rob -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, March 07, 2003 11:43 AM To: [EMAIL PROTECTED] Subject: print output from HTML::Parser Hi all perl script below works, and does what I hoped it would, but I don't seem to understand how to get it to p

print output from HTML::Parser

2003-03-07 Thread Steven_Massey
Hi all perl script below works, and does what I hoped it would, but I don't seem to understand how to get it to print out the result to a new file as opposed to stdout. Thanks for any help #!/usr/bin/perl -w use strict; use HTML::Parser; open(OUT, ">/share/file1") || die &

Re: HTML::Parser

2003-02-18 Thread Tom Beer
HTML::Parser and Spamassassin via FreeBSD ports and CPAN with the same results?! : : Are you certain it's installed? : : --- Tom Beer <[EMAIL PROTECTED]> wrote: : > Hi, : > : > can anyone explain how to detect the module? : > : > Can't locate loadab

Re: HTML::Parser

2003-02-18 Thread Paul
Are you certain it's installed? --- Tom Beer <[EMAIL PROTECTED]> wrote: > Hi, > > can anyone explain how to detect the module? > > Can't locate loadable object for module HTML::Parser in @INC (@INC > contains: lib > /usr/local/lib/perl5/site_perl/5.00

HTML::Parser

2003-02-18 Thread Tom Beer
Hi, can anyone explain how to detect the module? Can't locate loadable object for module HTML::Parser in @INC (@INC contains: lib /usr/local/lib/perl5/site_perl/5.005/i386-freebsd /usr/local/lib/perl5/site_perl/5.005 /usr/local/lib/perl5/site_perl/5.005/i386-freebsd /usr/local/lib/

Spamassassin & HTML::Parser

2003-02-15 Thread Tom Beer
l: Locking "spamassassin.lock" procmail: Executing "/usr/local/bin/spamassassin" Can't locate loadable object for module HTML::Parser in @INC (@INC contains: lib /usr/local/lib/perl5/site_perl/5.005/i386-freebsd /usr/local/lib/perl5/site_perl/5.005 /usr/local/lib/perl5/site_perl/5.00

RE: Using HTML::Parser question

2003-01-24 Thread Dan Muey
t; > > > i DON'T WANT THIS SCRIPT EITHER > > Hello world > > > > HTML > > my $body = 0; > my $title = 0; > my @body; > my @title; > my %body_attr; > > my $html = HTML::Parser->new(api_version => 3, >

Re: Using HTML::Parser question

2003-01-24 Thread Rob Dixon
Dan Muey wrote: > For clarity sake with all of the code and changes and stuff here is > the code that works mostly the way I want A virtue that - faith, hope and clarity. Sorry, /R -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

RE: Using HTML::Parser question

2003-01-23 Thread david
E i DON'T WANT THIS SCRIPT EITHER Hello world HTML my $body = 0; my $title = 0; my @body; my @title; my %body_attr; my $html = HTML::Parser->new(api_version => 3, text_h => [\&text,'dtext'],

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
er tags except comment and script should be > included > 4. attribute from body should not be part of body > > #!/usr/bin/perl -w > use strict; > > use HTML::Parser; > > my $text = < > HI Title > heaD STUFF > > > hI HERE'S CONTENT i WANT >

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
the same data as the body > contents, so there was no way to separate it fomr the content > # removed all html from the body content > > use HTML::Parser; > > my $temp; > my $html = HTML::Parser->new( > api_version => 3, > text

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
example with fetched the title ok but # it made the attributes :: bgcolor="red"=link="#EOEOEO" # the attributes were in the same data as the body contents, so there was no way to separate it fomr the content # removed all html from the b

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
: > 1. get title > 2. get body but without comment and script > 3. all other tags except comment and script should be > included 4. attribute from body should not be part of body > > #!/usr/bin/perl -w > use strict; > > use HTML::Parser; > > my $text = < >

RE: Using HTML::Parser question

2003-01-23 Thread david
included 4. attribute from body should not be part of body #!/usr/bin/perl -w use strict; use HTML::Parser; my $text = < HI Title heaD STUFF hI HERE'S CONTENT i WANT i DON'T WANT THIS SCRIPT EITHER Hello world HTML my $body = 0; my $title = 0; my @body

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
gt; > tags #2 - get body tag attributes my $body_attributes = IE in > > this example #it'd be 'bodytag=attributes' > > > > grabs the title and body text and attributes: > > #!/usr/bin/perl -w > use strict; > > use HTML::Parser; > >

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
; tags #2 - get body tag attributes my $body_attributes = IE in > > this example #it'd be 'bodytag=attributes' > > > > grabs the title and body text and attributes: > > #!/usr/bin/perl -w > use strict; > > use HTML::Parser; > > my $tex

Re: Using HTML::Parser question

2003-01-23 Thread david
' > grabs the title and body text and attributes: #!/usr/bin/perl -w use strict; use HTML::Parser; my $text = < HI Title heaD STUFF hI HERE'S CONTENT i WANT i DON'T WANT THIS SCRIPT EITHER HTML my $body = 0; my $title = 0; my @body; my @title;

RE: Using HTML::Parser question

2003-01-23 Thread Dan Muey
st trying to grab the body contents without > comments or script stuff. > > So far this module is really cool and handy!! > > #!/usr/bin/perl > > use HTML::Parser; > > my $text = < > > HI Title > heaD STUFF > > > hI HERE'S CONTENT i WANT &g

Using HTML::Parser question

2003-01-23 Thread Dan Muey
thout comments or script stuff. So far this module is really cool and handy!! #!/usr/bin/perl use HTML::Parser; my $text = < HI Title heaD STUFF hI HERE'S CONTENT i WANT i DON'T WANT THIS SCRIPT EITHER HTML my $html = HTML::Parser->new(

Re: use of HTML::Parser, HTML::FormatText

2002-04-05 Thread drieux
On Thursday, April 4, 2002, at 11:46 , M z wrote: [..] > $tree = HTML::Tree->new(); > $tree->parse_file(); > print X1 "$tree\n"; [..] Wow - had not even thought about doing the 'open' by hand. I had merely taken a list of files from the command line and let the 'tree' open and parse them. I'd

Re: use of HTML::Parser, HTML::FormatText

2002-04-04 Thread M z
t of the html > > I repeat that basic trick set to parse out the rows > and tables > for other stuff - since I need to parse out of : > > " > List Grovellor Says > List Grovellor > Says WIDTH="60%" ALIGN="center"> ALIGN="center"

Re: use of HTML::Parser, HTML::FormatText

2002-03-31 Thread drieux
the fact that I found "Frodo" on the hobbits mailing lists, and that he has the email address [EMAIL PROTECTED] - which is to say I found the TreeBuilder simpler to use than trying to work out the HTML::Parser and HTML::FormatText stuff directly, it provides some 'class extensions

use of HTML::Parser, HTML::FormatText

2002-03-31 Thread M z
hello, in conjunction, I was looking into this module HTML to take out all the HTML I have in several files. Namely, the data I want is between tags data does anyone have any practical experience using this module to do just that? what I really want to do is read in a huge file, say slurp it i

Trouble with HTML::Parser

2002-03-29 Thread Ron Goral
ogEntry(\*STDERR,"dgformapper","MapFormData", "Could not open $formUrl",$!); my $p = HTML::Parser->new (api_version => 3, start_h => [\&procStart, "tagname,attr,attrseq"], end_h => [\&proc

Re: HTML::Parser

2001-12-12 Thread _brian_d_foy
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Walter Valenti) wrote: > Hi, i'm looking for some SIMPLE examples of HTML::Parser module. > > I'm find some examples but are complex. look at some of its subclasses, like HTML::LinkExtor. Gisle has als

HTML::Parser

2001-12-12 Thread walter valenti
Hi, i'm looking for some SIMPLE examples of HTML::Parser module. I'm find some examples but are complex. Thanks Walter _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -- To unsubscri

Re: HTML::Parser

2001-10-21 Thread _brian_d_foy
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Sunthari) wrote: > How do I use HTML::Parser to visit each urls.I need to > extract some lines in each pages. to extract URLs use HTML::SimpleLinkExtor :) -- brian d foy <[EMAIL PROTECTED]> - Perl services for hire C

Re: HTML::Parser

2001-10-21 Thread Sunthari
Hi, I have simple q for you. How do u use HTML::PARSER to extract some information. I have made a search using WWW::Search and received a list of URLs.Meaning, the following are extraction from my codes: my $search = new WWW::Search ('AltaVista'); $search->maximum_t

HTML::PARSER

2001-06-25 Thread Prachi Shroff
Hi, Can somebody please explain me wha exactly does the HTML::PARSER module do? like if I use the parse() methoddoes it return me all text after extracting all the HTML tags? I could not find a proper expalnation to it in any book or documentation online. thanks, Prachi