var names = yunying_name.split(","); for (var i = 0; i < names.length; i++) { names[i] = names[i].trim(); } $("#yunying_name").val(names);
names=["a","b","c"];