$(this).val()
<input onblur="this.value = this.value.replace(/\B(?=(?:\d{3})+(?!\d))/g, ' ');" name="cost" value="" type="number">