now, i work on yii. i used chtml dropdown to show year, when i choose 2015, i want generate table on 2015. and when i choose 2016, will show 2016 table. here is my chtml dropdown code :
<?php
echo "Periode Tahun : ".CHtml::dropDownList('list_period_active', $id_periode,$list_period_active);
?>
and here is my javascript code :
<script type="text/javascript">
$('#list_period_active').change(function (){
/*
$.fn.yiiGridView.update('penilaian-ptsp-periode-grid', {
data: {'period':$('#list_period_active').val()}
});
*/
$('#box-table-a').load( { document.URL + ' #box-table-a',
data: {'period':$('#list_period_active').val()}
});
return false;
});
</script>
note :above script doesnt work and dont show an error