I have this function :
function boldString(str, find){
return str.replace(find, '<b>'+find+'</b>');
}
It works, except that it is case sensitive.
I could to-lower-case the str and find text before running the replace, But I want the function to return the original capitalization in the str field
So if I pass in 'Apple' for the str, and 'ap' for the find, I want the function to return 'Apple'.