今天来简单说一下Razor视图引擎语法相关的和视图类。

添加一个MvcTest项目,继续添加一个Home控制器,完成index的视图添加。我们就在index这里分析razor视图引擎。下面是home控制器代码

 1 using System;
 2 using System.Collections.Generic;
 3 using System.Linq;
 4 using System.Web;
 5 using System.Web.Mvc;
 6 
 7 namespace MvcTest.Controllers
 8 {
 9     public class HomeController : Controller
10     {
11         //
12         // GET: /Home/
13 
14         public ActionResult Index()
15         {
16             return View();
17         }
18 
19     }
20 }
View Code

相关文章:

  • 2022-02-10
  • 2022-12-23
  • 2022-12-23
  • 2021-10-11
  • 2022-01-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-31
  • 2021-09-26
  • 2021-07-28
相关资源
相似解决方案