1.Html.Action返回的指向指定控制器指定action的超链接标签<a>标签.如果没有指定controller,则默认为本页面对应的Controller.

如<%:Html.Action("TopNavigation","Email") %>

返回<a href="/Email/TopNavigation"></a>

 

2.Url.Action返回的是指定控制器指定action的完整URL地址

<form name="form1" action="<%:Url.Action("Reply","LatestJoinCompany") %>" method="post">

<a href="<%:Url.Action("SelectDetail","OutBox",new{letterid=m.LetterID}) %>"><%=m.LetterTitle %></a>

<%:Url.Action("SelectDetail","OutBox",new{letterid=m.LetterID}) %>返回\OutBox\SelectDetail\?letterid=m.LetterID

相关文章:

  • 2022-12-23
  • 2021-12-10
  • 2021-10-05
  • 2022-12-23
  • 2021-07-05
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-07-23
  • 2022-12-23
相关资源
相似解决方案