var str_plastic_pipe = $('#plastic_pipe').val(); console.log(str_plastic_pipe); str_plastic_pipe.replace(/,/, '.');