Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > http request, get html, parse it, print string... how best?

Reply
Thread Tools

http request, get html, parse it, print string... how best?

 
 
willykk@my-deja.com
Guest
Posts: n/a
 
      04-17-2005
Hi folks,

Can someone point a hobby java beginner get some tutorial / sample /
code snippet that shows how to grab an url over http (html file), and
parse it to extract some information?. I'm looking for the most elegant
/ shorter path, btw: I'm trying to do this from a client-side java
app...

Say, I want to grab (http get) the url
http://www.host.com/data/something.c...omething=stuff

and get as a result all the information between <sometag> and
</someothertag> (or between '---something--' and '--somethingelse')
into a string?

what would be the best way to parse it? Are there any built-in HTML
parsers in J2SE 5.0 (say for instance I want to remove all html tags).

I haven't coded with java code in a long, long time and when I did, I
only dealt with local files, not network i/o (btw: I run Java apps
daily, like the beatiful swing-based Photomesa digital photo browser, I
just don't code 'em .

Thanks in advance, and sorry if this was the wrong newsgroup for such a
question...

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
HTTP SOAP/HTTP GET/HTTP POST milan_9211 Software 0 01-10-2011 02:10 PM
Want help on how we convert output to tabular format Using the expat parser (http://expat.sourceforge.net/) i have to parse the following xml file and print it on the screen in tabular format. sharan XML 1 10-26-2007 01:20 PM
Using the expat parser (http://expat.sourceforge.net/) i have to parse the following xml file and print it on the screen in tabular format. Want a c program on that! sharan XML 1 10-26-2007 07:56 AM
Problem - I want to print Current Output of Pdf file and should print once.I get print dialog box but it is not working keto Java 0 05-30-2007 11:27 AM
Unlarging the print to print using PDF file to print Bun Mui Computer Support 3 09-13-2004 03:15 AM



Advertisments