我想在以下链接中发送2个参数?我该怎么做?这个想法?
var tarnsfer == true;
<a href="/Contacts/Register/' + row.ID + '" class="m-portlet__nav-link btn m-btn m-btn--hover-accent m-btn--icon m-btn--icon-only m-btn--pill" title="Rehbere Taşı"><i class="la la-book"></i></a >
控制器;
public ActionResult Register(int id, bool tranfer)
{
}
答案 0 :(得分:1)
var tarnsfer == true;
<a href="/Contacts/Register?id=' + row.ID + '&transfer='+transfer" class="m-portlet__nav-link btn m-btn m-btn--hover-accent m-btn--icon m-btn--icon-only m-btn--pill" title="Rehbere Taşı"><i class="la la-book"></i></a >
答案 1 :(得分:0)
你应该使用GET。生成如下链接:
/Controllet/Register/?param_1=123¶m_2=blahblahblah