(function($){ $.fn.sliderTelepatic = function(target = false){ //Pick the element to change if(!target){ target = $(this).parent().find('label').find('span'); } //Monitoring the change $(this).on('change', function(item, i){ $(target).html( item.currentTarget.value + "%" ); }); } })(jQuery);