var str = "123/1234/1231/23";
var
str =
"123/1234/1231/23"
;
str = str.replace(/
//g,"-");
alert(str)