For example if a word is "Users" and the replacement is "utilisateurs", is there some kind of function that will allow me to conver the replacement string to the same level of capitals/non-capitals as the original word?
This is a final part of a major language translation using jquery, textnodes, exact and partial string matching.
Now I just want to make sure as the final and professional touch, is to make sure the case of the translated/replaced words, match the case of the original words/phrases.
I am not sure how I can apply this as a replace call.
I want this to be as a function
function CopyCase(original,new) {
// copy the case of the original to the new
}
Only not sure how to do that.