Multiple choice css

How do you make each word in a text start with a capital letter?

  1. text-transform:uppercase

  2. text-transform:capitalize

  3. You can't do that with CSS

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

text-transform:capitalize makes the first character of each word uppercase while preserving the rest. Option A would make the entire text uppercase, not just the first letter of each word. CSS definitely supports this transformation.

AI explanation

The correct CSS property/value is text-transform:capitalize, which capitalizes only the first letter of each word while leaving the rest of the letters unchanged. text-transform:uppercase instead converts every letter in the text to uppercase, which is not what the question asks for. This is a standard, well-documented CSS text-transform behavior confirmed by MDN and other CSS references.