I have users list table how i can navigate on url: "../users/showprofile?userid="
I want to make table when user clicks on table row navigate on current user profile
Thanks
Without using jQuery, assuming you're in a foreach loop like something below, just change the tr
definition to be something like:
@foreach (var user in Model.Users) { <tr onclick="location.href = '@(Url.Action("ShowProfile", "Users", new { userId = user.UserId }))'"> //rest of your markup for that table row </tr> }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With