From the course: CSS: Selectors
Unlock the full course today
Join today to access over 24,400 courses taught by industry experts.
Form controls: :read-only and :read-write - CSS Tutorial
From the course: CSS: Selectors
Form controls: :read-only and :read-write
- [Instructor] Next up, let's look at the read only and read write CSS sudo classes. Read only is about the information on your page that's well, read only. Read write is about the information that can be changed on your page. Looking at this page, you may think you know what's read only and what's read write but let's dig into it a little more because it's a little more complex than you might think. First, let's look at our HTML. Here on line four in the HTML, this paragraph has the content editable attribute set. And this indicates that the paragraph may be changed on the page. Those changes aren't saved, and you're going to need something in order to make those changes permanent. But just to show you, I changed the text. So I just clicked right there inside of the display area and typed something new in that particular paragraph. Notice the HTML doesn't change but the display value here on the page has changed. Likewise, down here on line 40, you'll see that we have a text area…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
(Locked)
Form controls: :required and :optional; :enabled and :disabled5m 55s
-
(Locked)
Form controls: :read-only and :read-write5m 57s
-
(Locked)
Form control states: :indeterminate, :default, :checked6m 41s
-
(Locked)
Text fields: :autofill, :placeholder-shown7m 2s
-
(Locked)
Error checking: :valid, :invalid, :in-range, :out-of-range8m 15s
-
(Locked)
-
-
-