Hi,
I have such a code. I want to convert this code to the code below.
When you select it, the page will be PostBack and that url will go.
<div class="dropdown-menu">
@foreach (var item2 in Model.SubCustomers)
{
<a class="dropdown-item" asp-controller="Home" asp-action="CustomerBranch" asp-route-Code="@item2.Code" asp-route-returnUrl="@returnUrl">@item2.Code / @item2.PublicTitle/ @item2.AddressDetail</a>
}
</div>
I want to change below
<select class="js-example-basic-single" name="state">
@foreach (var item2 in Model.SubCustomers)
{
<option asp-controller="Home" asp-action="CustomerBranch" asp-route-Code="@item2.Code" asp-route-returnUrl="@returnUrl">
@item2.Code / @item2.PublicTitle/ @item2.AddressDetail
</option>
}
</select>