Mono Class Library: System.Web.HttpResponse Overview | Members

System.Web.HttpResponse.Redirect Method

Instructs the client to be redirected to a new url.

public void Redirect (string url, bool endResponse)

Parameters

url
The url to redirect to.
endResponse
Whether processing must be stopped immediately.

Remarks

This redirects the HTTP client to the new location.

This sends an HTTP 302 status code back to the client and clears all of the headers and content generated so far. The contents are replaced with a dummy HTML page that will point to the new page in case that the client does not automatically follow the redirection.

If endResponse is true then processing is stopped at this point and controls is not returned to the caller.

Requirements

Namespace: System.Web
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0