The cleanest way would be to add two forms on your page - one for login and one for registration. It should look something like:
using (Html.BeginForm("Login", new { action = "Login", controller = "Account"}, FormMethod.Post)) {
@Html.LabelFor(m => m.Username)
@Html.TextBoxFor(m => m.Username)
@Html.LabelFor(m => m.Password)
@Html.PasswordFor(m => m.Password)
<input type="submit" />
}
.
using (Html.BeginForm("Register", new { action = "Register", controller = "Account"}, FormMethod.Post)) {
@Html.LabelFor(m => m.Username)
@Html.TextBoxFor(m => m.Username)
@Html.LabelFor(m => m.Password)
@Html.PasswordFor(m => m.Password)
@Html.LabelFor(m => m.Confirm)
@Html.PasswordFor(m => m.Confirm)
<input type="submit" />
}
For more informmation plz refer link: http://www.andrewdenhertog.com/asp-net/using-multiple-submit-buttons-in-an-html-form-in-asp-net-mvc/