shankar <[EMAIL PROTECTED]> wrote:
>Your code is not running.I can't import  the WebConversation and WebResponce class
>
>Please ....
>Russell Gold wrote:
>
>> I  want to count the number of hrefs in one html file
>>
>> I assume you don't mean a static file that you can look at by hand? (That would be 
>too easy)
>>
>> If you mean that you want to do it dynamically, try HttpUnit 
><http://httpunit.sourceforge.net>:
>>
>> WebConversation wc = new WebConversation();
>> WebResponse wr = wc.getResponse( "http://..." );
>> int numHrefs = wr.getLinks().length;
>>
>> Pretty simple.

Did you download HttpUnit and JTidy? Are they in your classpath? Are you trying to 
import 'com.meterware.httpunit.*'?

Can you be more specific about what is not working?

------------------------------------------------------------------------
Russell Gold                     | "... society is tradition and order
[EMAIL PROTECTED]    (preferred)  | and reverence, not a series of cheap
[EMAIL PROTECTED]              | bargains between selfish interests."
[EMAIL PROTECTED]       |   - Poul Anderson, "Iron"

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to