[ale] Perl Question
James P. Kinney III
jkinney at localnetsolutions.com
Thu Sep 26 16:27:00 EDT 2002
Fletch can tell you a one liner to do it. I'm not that elegant.
The main tool you want to use is the very excellent CGI perl module from
Lincoln Stein.
It has a plethora of tools that simplify getting data from structures
returned from web page form submits. It is also very well documented.
If all you have is just the raw page with the data stuck inbetween a
textarea tag, split is a good choice here.
$data is the storage tank for the entire page.
($pre, $post)=split(/\<textarea\>/, $data); #now $post starts with what
you want
($goodies, @junk)=split(/\<\/textarea\>/, $post); # $goodies has just
the stuff between the first textarea tags.
On Thu, 2002-09-26 at 16:06, cfowler wrote:
> Okay I started doing some perl for testing and have a quick question.
>
> I have grabed a web page and it is stuck in $resp->content
>
> How can I walk through that line for line looking for data.
>
> I actually need what is between <textarea> </textarea>. The first
> instance of that.
>
> Thanks,
> Chris
>
>
>
>
> ---
> This message has been sent through the ALE general discussion list.
> See http://www.ale.org/mailing-lists.shtml for more info. Problems should be
> sent to listmaster at ale dot org.
--
James P. Kinney III \Changing the mobile computing world/
President and CEO \ one Linux user /
Local Net Solutions,LLC \ at a time. /
770-493-8244 \.___________________________./
GPG ID: 829C6CA7 James P. Kinney III (M.S. Physics)
<jkinney at localnetsolutions.com>
Fingerprint = 3C9E 6366 54FC A3FE BA4D 0659 6190 ADC3 829C 6CA7
This is a digitally signed message part
More information about the Ale
mailing list