Your specification is incomplete.

It is simple, not incomplete.

Actually it was ambiguous :) Se below to see what I mean (and probably what the post that said it was incomplete meant)

What if it says:

       <p>Data that I <b>need</b></p>

Do you want <b> in your response?  Or stripped?  Or that part of it not

included?

I don't care.
...
And why is <p> interesting to you, but not <title>?  those are both "text".
You'll need to explain it by more than just one example.  What
if it's in a table?  What if it's the caption for an image?

...

Basically, right now I just need the HTML to Text output, like I explained.

"HTML to Text" would seem to mean you do *not* want any HTML in your text, and also *any* text, including the title text. Also it could mean makein <b>'s into *' s and <i>'s in to /'s and <u> into _'s and links and images into refernced footnotes, lists into * or i. or 1. formatted lists or tabels into formatted text, etc etc...

To make it "complete" I think this is what you mean (and its not ambiguouse in any way ;p)

"I want to grab strings between the p tags in this exact block of HTML"

to which I would reply:

my @strings = $html =~ m{<p>(.*)</p>}g;

which I am able to do because I don't have to guess how you interpret "HTML to text", especially when "HTML to text" can be a very very very complicated thing with many many degrees of what that means exactly to a given person an situation (non of which we can know unless you tell us (IE by not being incomplete or ambiguouse)

HTH :)

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to