I am new to Razor. I am doing a project for uni and I am stuck at this point. I cant figure out the way to read value from the option tag. My way of thinking is that the client selects the phone name and then I can display full details of it.

<form name="dropdown" id="dropdown" method="post">

        <table>
            <tr>
                <td><select id="phone1" name="option11">
                    @foreach(var row in db.Query(selectQuery)){
                    <option id="option1" >@row.Brand</option>
                    }
                </select></td>
                <td><select>
                    @foreach(var row in db.Query(selectQuery)){
                    <option value="Phone 2">@row.Brand</option>
                    }
                </select></td>
            </tr>
        </table>
       <input type="submit" class="show-popup" data-showpopup="1" value="Click to Comapre" >
    </form>

Related posts

Recent Viewed