Multiple choice technology web technology

Which HTML attribute is used to define inline styles?

  1. styles

  2. class

  3. font

  4. style

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

The 'style' attribute in HTML is used to apply inline CSS directly to an element. For example:

Red text

. The 'class' attribute is for external/internal CSS, 'styles' is not a valid HTML attribute, and 'font' is a deprecated tag.