@using (Html.BeginForm("Register", "Account", new { sourceType = Request.QueryString["sourceType"] },FormMethod.Post))

 

http://localhost:7294/ccount/Register?sourceType=1

 

则获取sourceType=1

视图页面直接获取url get传值,

1.@Request.QueryString["look"]

2.@ViewContext.RequestContext.HttpContext.Request.Params["look"]

 

 

 

参考:https://www.cnblogs.com/firstcsharp/p/3238321.html

https://www.cnblogs.com/zinan/p/6479417.html

相关文章:

  • 2021-08-26
  • 2022-12-23
  • 2021-12-05
  • 2021-10-01
  • 2020-07-30
  • 2021-10-04
  • 2021-08-21
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-02
  • 2021-06-20
  • 2022-12-23
  • 2021-12-06
相关资源
相似解决方案