how can I call jquery ajax method when I select a data in a selection then perform a SELECT query from the selected data
.... then i want to show the result from the query in the #info div
Can someone help me?
html looks like this
<form action="details.php" method="post" >
<select>
<option value="volvo">Volvo</option>
<option value="saab">Saab</option>
<option value="mercedes">Mercedes</option>
<option value="audi">Audi</option>
</select>
<input type="submit" value="Details" name="submit" id="submit" />
</div>
<div id="info">
//display details or result from the query in details.php
</div>
$(document).ready(function() {
$("#submit").submit(function(){
$.ajax({
//i dont know how this works
});
});
});
Im newbie at jquery with ajax , any help will be appreciated...