js替换所有冒号

t = t.replace(/:/g, '');

/g表示所有

以下是替换第一个冒号
t = t.replace(':', '');

猜你喜欢

转载自cuityang.iteye.com/blog/2411765