Routing in ASP .Net MVC

WEBINAR:
On-Demand

Full Text Search: The Key to Better Natural Language Queries for NoSQL in Node.js


Routing is a pattern matching system which identifies the incoming request and decides what to do with that request. So the usual process will be carried out by this mechanism is that it maps the URL to a particular method (action) on a particular controller. The actions gets executed and returns an instance of ActionResult which handles the logic for rendering the HTML content in user's browser.

At run time the routing engine matches the incoming request URL pattern against the URL patterns defined in the Route table and process that accordingly.

Defining Route

A typical MVC project defines a 'Global.asax' file, which contains a single method 'Application_Start' within which various calls are made to various configuration methods to set up the application's working state. One of these calls is to the 'RegisterRoutes' method of the 'RouteConfig' class found in the 'App_Start' folder of the project which is responsible for configuring the routes for the application.




Comments

  • There are no comments yet. Be the first to comment!

Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • In the past, security was a major obstacle in moving workloads to the cloud. Today, the main obstacle to cloud adoption is the pain of migrating data. But not anymore. A data migration project using purpose-built tools that automate procedures and allow real-time testing can reduce the amount of downtime from hours or days to minutes or seconds. This eBook summarizes the major migration pain points, breaks down the flaws in traditional approaches, and illustrates how modern tools help businesses stay agile by …

  • Mobility is reaching an inflection point in enterprise. Smart enterprises are moving away from tactical point solutions for mobile device management, looking instead for a secure, comprehensive, unified, and future-proof mobile-app platform. Enterprise applications are now at the heart of mobile productivity, data is shared outside the enterprise walls, and the data itself may reside on multiple devices and clouds. Read this guide to learn how a unified endpoint management (UEM) solution is critical to …

Most Popular Programming Stories

More for Developers

RSS Feeds

Thanks for your registration, follow us on our social networks to keep up-to-date