Sentence Case | JavaScriptSource

Sentence Case

JavaScriptSource Staff Aug 1, 2007

General

Use this script to properly format form submissions. The beginning of each sentence will be capitalized, the rest of the sentence will be lower case.


Notes

Source Code

Paste this source code into the designated areas.

External file

Paste this code into an external JavaScript file named: sentenceCase.js


Head

Paste this code into the HEAD section of your HTML document.


Body

Paste this code into the BODY section of your HTML document


Leave a Response

(8 comments)

Just change the size in the input element.

Lee Sep 5, 2007

Let me repeat myself again: It's not meant to do all that. It's what it says: sentence case, which means capitalize the next word after a period and make the rest lowercase. It does what it was create for quite nicely.

Lee Sep 5, 2007

If text width more than the width of the input, after you've enter new letter it returns you to the begining of the text, I think it's not convinient.

Toha Aug 8, 2007

See the response above to compassman.

Lee Aug 7, 2007

It's not meant to do all that. It's what it says: sentence case, which means capitalize the next word after a period and make the rest lowercase. It does what it was create for quite nicely.

Lee Aug 7, 2007