console.log(parseInt('1234feiniaomy.com')) //1234
console.log(parseFloat('123.4feiniaomy.com')) // 123.4
var num = '123.4我爱中国'.replace(/[^\d.]/g, "");
console.log(num); //123.4
var num = '1234mycom'.match(/\d+(\.\d+)?/g);
console.log(num); //['1234']
var num2 = '123.4mycom'.match(/\d+(\.\d+)?/g);
console.log(num2); //['123.4']
var num4 = 'm123.55sd58sd6f'.match(/\d+(\.\d+)?/g);
console.log(num4); //['123.55', '58', '56']