ASKER
<select id="myselect">
<option value="1">
<option value="2">
</select>
<select id="select_unit">
<option value="dollar">
<option value="pound">
</select>
$(function() {
$('#select_unit').change(function() {
var unit = $(this).val();
// remove all options
$('#myselect').empty();
if(unit == "dollar")
{
$('#myselect').append('<option value="1">1</option>');
$('#myselect').append('<option value="2">2</option>');
}
else if(unit == "pound")
{
$('#myselect').append('<option value="3">3</option>');
$('#myselect').append('<option value="4">4</option>');
}
});
});
ASKER
Asynchronous JavaScript and XML (AJAX) is a group of interrelated Web development techniques used on the client-side to create asynchronous Web applications. With AJAX, web applications can send data to and retrieve from a server asynchronously (in the background) without interfering with the display and behavior of the existing page. HTML and CSS can be used in combination to mark up and style information. The Document Object Model (DOM) is accessed with JavaScript to dynamically display and allow interaction with the information presented.
TRUSTED BY
Open in new window