To redirect the user to another page (either external or internal), we can use Redirect
method like below.
public ActionResult Index() { return Redirect("http://www.itfunda.com"); // redirects to external url } public ActionResult Index() { return Redirect("/FilesModels/Create"); // redirects to internal url }
Remember that to redirect to external url, we need to provide complete url starting with http. For internal redirect, url can be provided from root of the application.
Views: 155567 | Post Order: 55