I added the CSS to make the input fields appear as you see in the image (or on the example page). I made the labels display as block level elements, which were floated to the left. Then I assigned a width to the labels so that the input fields would all be a uniform distance away from the labels. I assigned a color and made the text bold.
With having only CSS in mind for such an effect, you can imagine an input box coupled with a label element. This label can act as a fancy placeholder for our input box and moves above the input field on focus. With an input box followed by a label, we can style things up easily with the adjacent element selector in CSS (+).
.class1.class2. The CSS id Selector. The id selector uses the id attribute of an HTML element to select a specific element. The id of an element is unique within a page, so the id selector is used to select one unique element! To select an element with a specific id, write a hash (#) character, followed by the id of the element. Use the CSS :checked pseudo-class and the adjacent sibling selector (+). This will apply to any label that directly follows a checked radio button.
- Dokumentarfilm tips
- Skattetillägg skatteverket
- Barnbidrag över sommaren
- Skapa online kurser
- Varme djur
- Stadsbyggnadskontoret malmö ritningar
- Informationsfrihet regeringsformen
- Psy gamma
- Uppskrivning körkort
Here I am hiding the label until the user types in the input, thus hiding the placeholder. I use a nice transition effect to display the label. Automatically is disabled. This kind of situation we have used disabled selector in CSS.