● Mvc3 Chinese version:
●Mvc3 folder description:
| Folder |
Function |
| /Controllers |
Controllers processes input from the browser, determines what to do, and returns the result to the user |
| /Views |
Views includes a UI Template |
| /Models |
Models contains data and operations on Data |
| /Content |
Including images, CSS, and other static content |
| /Script |
Contains JavaScript files |
| /Add_data |
Contains database files (Note: It is usually used to save database files released along with the website, such as SQL express database and Access Database configured for the website. You can ignore SQL Server, MySQL, and other databases) |
●Mvc3 creation steps:
Step1. create an "empty" Asp.net mvc3 project and set the view engine to razor.
* Directly clicking "run" will directly access http: // localhost: 31207/. The resource cannot be found because there is no content in it. Select the Internet application template when creating the project. A default executable page is generated.
Step2. efcodefirst:
1) tool download
Ctp5 (Entity Framework feature): codefirst uses EntityCodeAutomatic database creation
Codefirst auxiliary tool: EF power tool Generate a model class based on the database and generate EF generated view to improve EF Performance