You are implementing an ASP.NET MVC 2 application. In the Areas folder, you add a subfolder named Product to create a single project area.
You add files named ProductController.cs and Index.aspx to the appropriate subfolders. You then add a file named Route.cs to the Product folder that contains the following code. (Line numbers are included for reference only.)
01 public class Routes : AreaRegistration
02 {
03 public override string AreaName
04 {
05 get { return "product"; }
06 }
08 public override void RegisterArea(AreaRegistrationContext context)
09 {
10 context.MapRoute("product_default",
"product/{controller}/{action}/{id}",
new { controller = "Product", action = "Index",
id = "" });
11 }
12 }
When you load the URL http://
/product, you discover that the correct page is not returned.
You need to ensure that the correct page is returned.
What should you do?