On Change select change Font size
by Faisal Khan Janjua
HTML
<div id="combodiv"></div>
<div id="demo">Font size changed to <span></span></div>
JavaScript
$(document).ready(function(){
var selectSize = "<select id='combo'>";
for( var i=8; i<=100; i++){
selectSize+='<option value="' + i +'">' + i + '</option>';
}
selectSize+="</select>";
$("#combodiv").html(selectSize);
$('select').change(function(){
var size = $(this).val();
$('#demo span').text(size).css('font-size', size+'px');
});
var selectVal = $("#combo").val();
$('#demo span').text(selectVal).css('font-size', selectVal+'px');
});