i have the following:
var S=\"hi how are you\"; var bindex = 2; var eindex = 6;
how can i remove all the chars from S that reside between
You can:
rebuild the string
var new_s = S.slice(1, bindex) + S.slice(bindex, eindex).replace(/\s/g, '') + S.slice(eindex)