[1721] in java-interest

home help back first fref pref prev next nref lref last post

slowly getting there

daemon@ATHENA.MIT.EDU (Steve Rooks)
Fri Sep 15 05:58:06 1995

From: Steve Rooks <srooks@cmprime.att.com>
Original-From: Steve Rooks <cmprime!srooks>
To: java-interest-digest@java.sun.com
Date: Fri, 15 Sep 1995 0:07:33 EDT


I'm currently trying to read a passwd protected page. Here's the 
html for teh page,

if you are a registered user you can <A HREF="/free/home.html">
click here to go to our Free Services. </A>

When viewing this from netscape , a dialogue window pops up to
ask for name and password.

So in my code i'm trying to read teh page. Here's a small code frag.

URL url = new URL("http://www.esi.co.uk/free/home.html");
url.port = 80;
url.host="proxy";

InputStream is = url.openStreamInteractively();

while( (c = is.read()) != -1)
	{
	System.out.write(c);
	}


My output ..

<HTML>
<HEAD>
<TITLE>Error</TITLE>
</HEAD>
<BODY>
<H1>Error 404</H1>

Not found - file doesn't exist or is read protected [even tried multi]

<P><HR><ADDRESS><A HREF="http://info.cern.ch/httpd_3.0/">CERN httpd 3.0</A></ADD
RESS>
</BODY>
</HTML>

What i don't understand , is where's the request to enter the password comming
from? As i mentioned, netscape handles this , but i'm clearly missing something.

thanks,

steve
-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com

home help back first fref pref prev next nref lref last post