$(document).ready(function(){
	$('select#frm_make').change(function(){
		$.get("chipPhp.php", { make: $("select#frm_make").val()}, function(data){
    		$('select#frm_model').html(data);
    		$('select#frm_engine').html('');
    		$('tr#results').html('');
    		$('select#frm_model option.top').attr('selected', 'selected');
  		});
		});
		
	$('select#frm_model').change(function(){
		$.get("chipPhp.php", { model: $("select#frm_model").val()}, function(data){
    		$('select#frm_engine').html(data);
    		$('tr#results').html('');
    		$('select#frm_engine option.top').attr('selected', 'selected');
  		});
		});
		
	$('select#frm_engine').click(function(){
		$.get("chipPhp.php", { engine: $("select#frm_engine").val()}, function(data){
    		$('tr#results').html(data);
  		});
		});
		
});
