Regex replace for String, 3 characters from the end -


i have been able add space string in input field using following:

onkeypress="this.value=this.value.replace(/^(\w{5})(?=\w)/,'$1 ')" 

but count start end of line, , add space after user input has stopped. i've tried onblur, not seem work in chrome.

any tips?

thanks

just guess -

onkeypress="this.value=this.value.replace(/(\w{5})(?=\w$)/,'$1 ')" 

Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -