Re: Read source code of a web page

From: UAError (null_at_null.null)
Date: 01/23/05


Date: Sat, 22 Jan 2005 20:31:01 -0500


"Nick Malik [Microsoft]" <nickmalik@hotmail.nospam.com>
wrote:

>The advice from UAError is only appropriate if the web site is on YOUR
>computer.

Surely you mean a computer within your domain, not your own
local computer? When I'm wrong, I'm wrong but the latter
would seem so restrictive that it is useless. The sample

How To Use WebClient Class To Make HTTP Requests
http://support.microsoft.com/default.aspx?scid=kb;en-us;328820

states that WebClient supports
- Basic authentication
- Integrated Windows authentication

<snip>
>All subsequent pages on the site require the cookie. Web browsers already
>do this. If a cookie comes from a web site, with instructions for how long
>the cookie should remain in the browser, the browser will automatically pass
>the cookie back to every subsequent request from that web site.

I was under the (now obviously mistaken) impression that
WebClient was like a stripped down browser. I guess I should
have looked for a Cookies or CookieContainer property and
drawn my own conclusions when it wasn't there.

>You have to use the GET and POST methods of the HTTPWebRequest
>class to ask for the login page and to provide the credentials.

You had me confused here until I found the
HttpWebRequest.Method property, which was impossible to find
under "Public Methods" :)

Thanks for straightening this out.



Relevant Pages

  • Cookies
    ... Some of our customers are having problems logging into our web site. ... Once they login it puts a cookie in their browser to stay logged in. ...
    (comp.programming)
  • Re: Running a file on the computer from the server
    ... to run a file on the local computer from a web site. ... browser does not seem to see this as a link anymore. ... However if you have this link on the same web page on your local computer ...
    (microsoft.public.windows.inetexplorer.ie6.browser)
  • Re: Cookies
    ... Once they login it puts a cookie in their browser to stay logged in. ... computer if they are under the secure portion of our web site. ...
    (comp.programming)
  • Re: [SLE] enabling cookies
    ... When visiting new web site I am always asked if I would like to reject ... I have rejected cookie on one site and now I have some ... I have SuSE 10 and usualy I use Konqueror as a browser (I ... In Konqueror, select "Settings" from the top menu and then "Configure ...
    (SuSE)
  • Re: Authentication when browsing
    ... answer A can be correct if you enable your cookie, ... remember you have been to web site. ... you notice that you have to authenticate and reauthenticate at ... > C-Disable cookies in your browser ...
    (microsoft.public.cert.exam.mcse)

Loading