Theodor-

Please don't misinterpret... I really was trying to clarify your question.
:-)

I still don't understand what you are saying "access a generated HTML page"?
Do you mean a URL or a file? You can connect to any URL with java.net.URL.
It doesn't matter how the returned HTML is "generated", e.g. static .htm
file, Servlet, CGI, ASP. You connect via URL and you get an InputStream
which you can then parse to find the values you are looking for. Same
principal applies if you are opening a File off of the hard drive. Code
below.



import java.net.*;
import java.io.*;

public class URLReader {
    public static void main(String[] args) throws Exception {
        URL yahoo = new URL("http://www.yahoo.com/";);
        BufferedReader in = new BufferedReader(
                                new InputStreamReader(
                                yahoo.openStream()));

        String inputLine;

        while ((inputLine = in.readLine()) != null)
            System.out.println(inputLine);

        in.close();
    }
}





> -----Original Message-----
> From: A mailing list for discussion about Sun Microsystem's Java Servlet
> API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of
> Goulas, Theodor
> Sent: Wednesday, August 22, 2001 3:47 PM
> To: [EMAIL PROTECTED]
> Subject: Re: Accessing servlet-generated Html files!
>
>
> Hey, take it easy,
> that was just a question!
> I wanted to know if it is possible to access a generated  html page which
> contains some forms.
> Is this possible?
>
> Kevin Baynes wrote:
>
> > What are you asking?
> > How to connect from a servlet to a web URL and search the
> returned page for
> > a value?
> >
> > > -----Original Message-----
> > > From: A mailing list for discussion about Sun Microsystem's
> Java Servlet
> > > API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of
> > > Goulas, Theodor
> > > Sent: Wednesday, August 22, 2001 11:31 AM
> > > To: [EMAIL PROTECTED]
> > > Subject: Accessing servlet-generated Html files!
> > >
> > >
> > > Hi everyone,
> > >
> > > I was wandering if it is possible to access a servlet-generated
> > > Html-file to search this.  Lets say I want to get a parameter which is
> > > defined in a <form> Tag.
> > > How can I do that. (I mean only access this file)
> > >     I was trying to do something with URLConnection but the generated
> > > Html is inside a frame and this make thinks worse. :-(
> > >  I would appreciate for any ideas.
> > >
> > > Thanks in advance
> > >
> > > __________________________________________________________________
> > > _________
> > > 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
>
>
___________________________________________________________________________
> 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

___________________________________________________________________________
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

___________________________________________________________________________
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