js remove single quotes from string code example
Example 1: javascript remove quotes from string
var someStr = 'He said "Hello, my name is Foo"';
console.log(someStr.replace(/['"]+/g, ''));
Example 2: javascript remove specific character from string
var newString = oldString.replaceAll("character/string goes here", "");
// Example
var oldString = "Hello World!";
var newString = oldString.replaceAll("o", "");
console.log(newString);
// Prints 'Hell Wrld!' to console.