I have a list of users that is displayed from a SQL db. Each user is appended with a delete button. I am not sur ehow to retrieve the seller.id from the submitted form in Page.Request object.
@foreach(var seller in Db.GetUser())
{
<form method="post" id="form3"> @seller.FirstName
<INPUT TYPE="image" SRC="deleteButton.png" VALUE="X" name="@seller.I开发者_StackOverflow中文版d">
</form>
}
You should add a hidden input to the form containing the ID.
You can then add a parameter to your action with the same name.
精彩评论