Usuń cięcia z JavaScript String
str = str.replace(/\\/g, '')
feddynventor
str = str.replace(/\\/g, '')
function someFunction(site)
{
return site.replace(/\/$/, "");
}