I've tried this and I do not know if it is the right way:
HTML Code:
<div class="container-fluid">
<form class="form-inline">
<div class="form-group">
<label>Choose Records Per Page:</label>
<select class="form-control input-sm num_rec_per_page">
<option>5</option>
<option>10</option>
<option>50</option>
<option>100</option>
<option>150</option>
<option>200</option>
</select>
</div>
</form>
</div>
JAVASCRIPT Code:
<script>
$(document).ready(function(){
$("select.num_rec_per_page").change(function(){
$(".num_rec_per_page option:selected").val();
window.location="?num_rec_per_page=" + num_rec_per_page;
});
});
</script>
PHP Code
$num_rec_per_page=$_GET['num_re_per_page'];
So this code, when the variable changes, a refresh is made to the webpage, but I do not want that, can you help me??