I Want to add Options to Select Box using jquery, but my options comes from MYSQL databse table
here is method what i want:
function add_inst(va) {
alert(va);
}
<select id="test">
</select>
I want to select values from MySQL table with match value of va, then add these result as options to select id="test".
For example if i pass '12' to function add_inst like add_inst('12'), my SQL statement will be:
SELECT *
FROM tbl1
WHERE col1='12'
after all the values return from mysql will be add to select id="test" as options.